From 47f50f78df13659243b37463558bf800def343a4 Mon Sep 17 00:00:00 2001 From: Ed Wilde Date: Tue, 1 Aug 2023 10:39:43 +1200 Subject: [PATCH] Fix issue with reloading the page when expanded --- javascript/betternavigator.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/javascript/betternavigator.js b/javascript/betternavigator.js index 0c3a381..2681a82 100755 --- a/javascript/betternavigator.js +++ b/javascript/betternavigator.js @@ -52,6 +52,11 @@ function initialiseBetterNavigator() { if (getCookie('BetterNavigator') === 'open') { BetterNavigator.classList.add('open'); BetterNavigator.classList.remove('collapsed'); + + // update the button state + BetterNavigatorStatusButton.setAttribute('aria-expanded', 'true'); + BetterNavigatorStatusIcon.classList.remove('bn-icon-cog'); + BetterNavigatorStatusIcon.classList.add('bn-icon-close'); } if (BetterNavigatorLogoutForm) {