Add files via upload
This commit is contained in:
parent
f8cff3b3d0
commit
f0259bbcde
6 changed files with 902 additions and 0 deletions
15
script/script.js
Normal file
15
script/script.js
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
let titre = document.querySelectorAll(".titre");
|
||||
|
||||
for(let i = 0; i <titre.length; i++){
|
||||
titre[i].addEventListener("click", function(){
|
||||
let result = this.nextElementSibling;
|
||||
result.classList.toggle("active");
|
||||
|
||||
if(this.firstElementChild.innerText === "(Cliquez pour étendre)"){
|
||||
this.firstElementChild.innerText = "(Cliquez pour replier)"
|
||||
}
|
||||
else{
|
||||
this.firstElementChild.innerText = "(Cliquez pour étendre)"
|
||||
}
|
||||
})
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue