From e7c595bdca722858b022ac9ceb2736381f009149 Mon Sep 17 00:00:00 2001 From: polo Date: Sun, 7 Jun 2026 21:15:38 +0200 Subject: anti spam clic --- public/js/main.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'public/js/main.js') diff --git a/public/js/main.js b/public/js/main.js index d1459d5..1666b5c 100644 --- a/public/js/main.js +++ b/public/js/main.js @@ -29,11 +29,11 @@ function copyInClipBoard(link){ toastNotify('Cette adresse a été copiée dans le presse-papier:
' + link); } -function toastNotify(message){ +function toastNotify(message, duration = 5000){ // 5s par défault var toast = document.getElementById('toast'); toast.innerHTML = message; toast.className = 'toast show'; - setTimeout(function(){ toast.className = toast.className.replace('show', ''); }, 5000); + setTimeout(function(){ toast.className = toast.className.replace('show', ''); }, duration); } -- cgit v1.2.3