From bd74c40aff864bdd8b00816f14bc2275e52a7b6e Mon Sep 17 00:00:00 2001
From: laurentheirendt <laurent.heirendt@uni.lu>
Date: Wed, 25 Aug 2021 10:05:26 +0200
Subject: [PATCH] add layer id slug

---
 assets/js/box_hider.js | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/assets/js/box_hider.js b/assets/js/box_hider.js
index b91f5820..6a616093 100644
--- a/assets/js/box_hider.js
+++ b/assets/js/box_hider.js
@@ -1,10 +1,10 @@
-/** 
+/**
  * This is used to hide the sections of the index page
  * based on the URL fragment (a.k.a. "hash")
  */
 window.boxHider = (function() {
     function GetSelectedId() {
-        var boxId = window.location.hash;
+        var boxId = window.location.hash + '-card';
         if (boxId.length > 0) {
             return boxId.substring(1);
         }
@@ -24,10 +24,10 @@ window.boxHider = (function() {
     function GetSelectedBoxElement(id) {
         var allBoxesArray = GetAllBoxElementsArray();
         var element = document.getElementById(id);
-        
+
         if (allBoxesArray.includes(element)) {
             return element;
-        } 
+        }
 
         return false;
     }
@@ -61,7 +61,7 @@ window.boxHider = (function() {
         var boxId = GetSelectedId();
         if (boxId.length == 0) {
             // If there is no hash in the URL, just show all the boxes
-            ShowAllBoxes(); 
+            ShowAllBoxes();
             return;
         }
         // Otherwise, proceed to getting the corresponding div element
-- 
GitLab