From f1dec6ff07f73751514695b61014bfa39b94a840 Mon Sep 17 00:00:00 2001
From: rakshazi <osi@rakshazi.me>
Date: Wed, 03 Feb 2021 14:47:46 +0000
Subject: [PATCH] Fix customizeSidebar() error on non-english ids

---
 assets/js/index.js |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/assets/js/index.js b/assets/js/index.js
index 2d64647..380f402 100644
--- a/assets/js/index.js
+++ b/assets/js/index.js
@@ -105,7 +105,7 @@
         });
 
         const linkPositions = pageIds.map(function(id){
-          const heading = document.getElementById(id.replace('#',''));
+          const heading = document.getElementById(decodeURIComponent(id.replace('#','')));
           const position = heading.offsetTop;
           return position;
         });
@@ -340,4 +340,4 @@
 
 }
 
-window.addEventListener('load', loadActions());
\ No newline at end of file
+window.addEventListener('load', loadActions());

--
Gitblit v1.10.0