summaryrefslogtreecommitdiff
path: root/help3xsl/help2.js
diff options
context:
space:
mode:
Diffstat (limited to 'help3xsl/help2.js')
-rw-r--r--help3xsl/help2.js16
1 files changed, 11 insertions, 5 deletions
diff --git a/help3xsl/help2.js b/help3xsl/help2.js
index f62105dc62..54dd195ab3 100644
--- a/help3xsl/help2.js
+++ b/help3xsl/help2.js
@@ -217,10 +217,16 @@ debugInfo(getParameterByName("Debug"));
// Mobile devices need the modules and langs on page load
if (Math.max(document.documentElement.clientWidth, window.innerWidth || 0) < 960) {
- var e = new Event('change');
- var modules = document.getElementById('modules');
- var langs = document.getElementById('langs');
- modules.dispatchEvent(e);
- langs.dispatchEvent(e);
+ var e = new Event('click');
+ var modulesBtn = document.getElementById('modules');
+ var langsBtn = document.getElementById('langs');
+ var modules = document.getElementById('modules-nav');
+ var langs = document.getElementById('langs-nav');
+ modules.setAttribute('data-a11y-toggle-open', '');
+ modulesBtn.dispatchEvent(e);
+ if (langs) {
+ langs.setAttribute('data-a11y-toggle-open', '');
+ langsBtn.dispatchEvent(e);
+ }
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */