js faq
This commit is contained in:
@@ -20,11 +20,11 @@ var questions = document.getElementsByClassName(".field--name-field-question");
|
||||
|
||||
for (let i = 0; i < questions.length; i++) {
|
||||
const question = questions[i]
|
||||
question.addEventListener("click", toggleMenu);
|
||||
question.addEventListener("click", toggleFaq);
|
||||
}
|
||||
|
||||
|
||||
function toggleMenu(event) {
|
||||
function toggleFaq(event) {
|
||||
console.log(event);
|
||||
for (let i = 0; i < answers.length; i++) {
|
||||
const answer = answers[i]
|
||||
|
||||
@@ -86,8 +86,8 @@ header{
|
||||
// ul:is(.ul1 .sous-liste .ul2){
|
||||
// display: none;
|
||||
// }
|
||||
:hover ul div:first-child{
|
||||
li div{
|
||||
:hover ul {
|
||||
div:first-child li div{
|
||||
display: block;
|
||||
background-color: $white;
|
||||
padding: 1rem;
|
||||
@@ -99,19 +99,19 @@ header{
|
||||
}
|
||||
}
|
||||
}
|
||||
:hover ul div:nth-child(2){
|
||||
li div{
|
||||
display: block;
|
||||
background-color: $white;
|
||||
padding: 1rem;
|
||||
a{
|
||||
color: $black;
|
||||
&:hover{
|
||||
color: $blue-light;
|
||||
}
|
||||
}
|
||||
:hover ul {
|
||||
div:nth-child(2) li div{
|
||||
display: block;
|
||||
background-color: $white;
|
||||
padding: 1rem;
|
||||
a{
|
||||
color: $black;
|
||||
&:hover{
|
||||
color: $blue-light;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#block-burger { // menu burger à droite
|
||||
|
||||
Reference in New Issue
Block a user