반응형 JS챌린지5일차1 [JavaScript 30일 챌린지] : 5일차 .panel > *:first-child { transform: translateY(-100%); } .panel.open-active > *:first-child { transform: translateY(0); } .panel > *:last-child { transform: translateY(100%); } .panel.open-active > *:last-child { transform: translateY(0); } const panels = document.querySelectorAll('.panel'); function toggleOpen() { console.log('Hello'); this.classList.toggle('open'); } function toggleActive(e) {.. 2022. 2. 1. 이전 1 다음 반응형