Timeout de message JS
function sendFeedback(message, timeout = 5000)
{
let feedbackItem = document.querySelector('[item-type="feedback"]');
if (!feedbackItem) {
return;
}
feedbackItem.innerHTML = message;
feedbackItem.classList.add('active');
setTimeout(() => {
feedbackItem.feedbackItem.innerHTML = '';
}
, timeout);
}
Tiago F2