display none message druppal form faq

This commit is contained in:
2022-01-06 08:12:00 +01:00
parent 19dc0ede4c
commit dcf9cb3de4
3 changed files with 61 additions and 13 deletions
+14
View File
@@ -37,6 +37,20 @@ function toggleFaq(event) {
answer.classList.add('opened');
}
// fleche qui tourne faq
var questions = document.getElementsByClassName("field--name-field-question");
for (let i = 0; i < questions.length; i++) {
const question = questions[i]
question.addEventListener("click", toggleFaq);
}
function rotateFleche(event) {
console.log(event, this);
for (let i = 0; i < answers.length; i++) {
answers[i].classList.remove('opened');
}
}
// /////////////////