8 lines
236 B
JavaScript
8 lines
236 B
JavaScript
|
const search = document.querySelector('.search')
|
||
|
const btn = document.querySelector('.btn')
|
||
|
const input = document.querySelector('.input')
|
||
|
|
||
|
btn.addEventListener('click', () => {
|
||
|
search.classList.toggle('active')
|
||
|
input.focus()
|
||
|
})
|