summaryrefslogtreecommitdiff
path: root/modules/overlay/overlay-child.js
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2010-11-06 00:18:24 +0000
committerDries Buytaert <dries@buytaert.net>2010-11-06 00:18:24 +0000
commit755bf9cd70be27fafb1c2fd28920559e2d5f055c (patch)
treead22554ff2da32a3b4b2fe551000c16e9237762d /modules/overlay/overlay-child.js
parent7ab426ecae5e383ee1c662756e89320207f91cbd (diff)
downloadbrdo-755bf9cd70be27fafb1c2fd28920559e2d5f055c.tar.gz
brdo-755bf9cd70be27fafb1c2fd28920559e2d5f055c.tar.bz2
- Patch #896364 by frega, effulgentsia, Jacine, sun, David_Rothstein, Jeff Burnz, james.elliott, casey, mgifford: screen reader users and some keyboard only users need a clear, quick way to disable the overlay.
Diffstat (limited to 'modules/overlay/overlay-child.js')
-rw-r--r--modules/overlay/overlay-child.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/modules/overlay/overlay-child.js b/modules/overlay/overlay-child.js
index d0e4b8df8..4c2666cd9 100644
--- a/modules/overlay/overlay-child.js
+++ b/modules/overlay/overlay-child.js
@@ -57,6 +57,19 @@ Drupal.behaviors.overlayChild = {
// Attach child related behaviors to the iframe document.
Drupal.overlayChild.attachBehaviors(context, settings);
+
+ // There are two links within the message that informs people about the
+ // overlay and how to disable it. Make sure both links are visible when
+ // either one has focus and add a class to the wrapper for styling purposes.
+ $('#overlay-disable-message', context)
+ .focusin(function () {
+ $(this).addClass('overlay-disable-message-focused');
+ $('a.element-focusable', this).removeClass('element-invisible');
+ })
+ .focusout(function () {
+ $(this).removeClass('overlay-disable-message-focused');
+ $('a.element-focusable', this).addClass('element-invisible');
+ });
}
};