commit f2559fee5f7caeaa773fdd8708f11e2441976039
parent 668f37767c99c53a721ccb69930ce485e300260e
Author: Kévin Le Gouguec <kevin.legouguec@gmail.com>
Date: Mon, 8 Mar 2021 19:05:58 +0100
Remove hint to click for more info once a concert is displayed
Diffstat:
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/actualités.html b/actualités.html
@@ -17,7 +17,7 @@
</div>
<div id="event-details">
- <p>Cliquez sur un concert pour obtenir plus d'informations.</p>
+ <p class="hint">Cliquez sur un concert pour obtenir plus d'informations.</p>
<div class="details canceled" id="concert-2021-04-03">
<p class="detail date">Samedi 3 avril 2021</p>
@@ -72,11 +72,14 @@
document.head.appendChild(detailsStyle);
detailsStyle.sheet.insertRule('.details:not(.active) {display:none}');
+ var pHint = document.querySelector('p.hint');
+
var anchor = document.location.hash;
if (anchor.match(/#concert-/)) {
document.querySelector(anchor).classList.add('active');
document.querySelector(`a[href="${document.location.hash}"]`)
.classList.add('active');
+ pHint.style.display = 'none';
}
document.querySelectorAll('a.event').forEach((link) => {
link.addEventListener('click', function(click) {
@@ -94,6 +97,8 @@
prev.classList.remove('active');
}
link.classList.add('active');
+
+ pHint.style.display = 'none';
});
});
</script>