akf-forum/public/js/modal.js

3 lines
174 B
JavaScript
Raw Normal View History

2022-09-27 21:34:13 +03:00
for (const modal of document.querySelectorAll("[modal]"))
modal.onclick = () => {
document.querySelector(modal.getAttribute("modal")).classList.toggle('active')};