From 392c17efa084b92534e7130468116cc4522962d7 Mon Sep 17 00:00:00 2001 From: Calixte Denizet Date: Tue, 1 Oct 2024 16:57:34 +0200 Subject: [PATCH] Make the secondary menu button usable with the keyboard when NVDA is enabled It's a temporary workaround until bug 1921984 is fixed. --- web/app.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/web/app.js b/web/app.js index 2f18b6049..818e35173 100644 --- a/web/app.js +++ b/web/app.js @@ -2750,7 +2750,10 @@ function onClick(evt) { if ( this.pdfViewer.containsElement(evt.target) || (appConfig.toolbar?.container.contains(evt.target) && - evt.target !== appConfig.secondaryToolbar?.toggleButton) + // TODO: change the `contains` for an equality check when the bug: + // https://bugzilla.mozilla.org/show_bug.cgi?id=1921984 + // is fixed. + !appConfig.secondaryToolbar?.toggleButton.contains(evt.target)) ) { this.secondaryToolbar.close(); }