Kategória: Egyéb

document.addEventListener('DOMContentLoaded', () => { const reviews = document.querySelectorAll( '.testimonial-carousel .elementor-testimonial' ); reviews.forEach((review) => { const btn = document.createElement('div'); btn.className = 'read-more'; btn.textContent = 'Bővebben'; review.after(btn); btn.addEventListener('click', () => { review.classList.toggle('open'); btn.textContent = review.classList.contains('open') ? 'Kevesebb' : 'Bővebben'; }); }); });