Hi Dark Beccio,
You can achieve that with the following code:
window.onload = () => { const cardview = document.querySelector('smart-card-view'); const cards = cardview.querySelectorAll('smart-card'); for(let i = 0; i < cards.length; i++) { cards[i].onclick = () => { alert("click"); } }}
In the above code we get all smart-card instances inside the card view and add click event handler to them.
Hope this helps.
Best regards,
Peter Stoev
Smart UI Team
https://www.htmlelements.com/