From 90d2385b0bec1418b85e7f43f15d9fb83509ca3e Mon Sep 17 00:00:00 2001 From: ccd0 Date: Wed, 5 Aug 2015 19:07:46 -0700 Subject: [PATCH] Fix captcha scrollbar auto-hide bug. This fixes an issue where clicking the scrollbar of the image selection bubble would cause the QR to autohide, breaking the captcha. --- src/Posting/QR.coffee | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Posting/QR.coffee b/src/Posting/QR.coffee index bda59843c..be5ef55f9 100644 --- a/src/Posting/QR.coffee +++ b/src/Posting/QR.coffee @@ -155,7 +155,8 @@ QR = $.off d, 'scroll', QR.scrollLock inBubble: -> - d.activeElement in $$('.goog-bubble-content > iframe') + bubbles = $$ '.goog-bubble-content > iframe' + d.activeElement in bubbles or bubbles.some((el) -> el.getBoundingClientRect().bottom > 0) inCaptcha: -> (d.activeElement?.nodeName is 'IFRAME' and QR.nodes.el.contains(d.activeElement)) or (QR.hasFocus and QR.inBubble())