diff --git a/package.json b/package.json index 73f92a6..6c14ddb 100755 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "call-me", - "version": "1.0.14", + "version": "1.0.15", "description": "Your Go-To for Instant Video Calls", "author": "Miroslav Pejic - miroslav.pejic.85@gmail.com", "license": "AGPLv3", diff --git a/public/client.js b/public/client.js index 1eedfe2..d7cdaef 100755 --- a/public/client.js +++ b/public/client.js @@ -230,8 +230,8 @@ function handleNotFound(data) { function handleSignIn(data) { const { success } = data; if (!success) { - handleError('Username already in use. Try a different username.'); - setTimeout(handleHangUpClick, 2000); + handleError('Username already in use.
Please try a different one.'); + setTimeout(handleHangUpClick, 3000); } else { githubDiv.style.display = 'none'; signInPage.style.display = 'none'; @@ -327,6 +327,8 @@ function offerAccept(data) { showDenyButton: true, confirmButtonText: `Yes`, denyButtonText: `No`, + timerProgressBar: true, + timer: 10000, showClass: { popup: 'animate__animated animate__fadeInDown' }, hideClass: { popup: 'animate__animated animate__fadeOutUp' }, }).then((result) => { @@ -415,15 +417,15 @@ function handleLeave() { } // Handle and display errors -function handleError(message, error = false, position = 'top') { +function handleError(message, error = false, position = 'center', timer = 4000) { if (error) console.error(error); sound('notify'); Swal.fire({ position, - title: 'Warning', - text: message, icon: 'warning', - confirmButtonText: 'OK', + html: message, + timerProgressBar: true, + timer, showClass: { popup: 'animate__animated animate__fadeInDown' }, hideClass: { popup: 'animate__animated animate__fadeOutUp' }, }); @@ -433,10 +435,7 @@ function handleError(message, error = false, position = 'top') { function popupMsg(message, position = 'top', timer = 4000) { Swal.fire({ position, - title: 'Info', html: message, - icon: 'info', - confirmButtonText: 'OK', timerProgressBar: true, timer, showClass: { popup: 'animate__animated animate__fadeInDown' }, diff --git a/public/style.css b/public/style.css index c80f253..5b5921d 100644 --- a/public/style.css +++ b/public/style.css @@ -32,6 +32,7 @@ body { padding: 5px; top: 10px; right: 20px; + font-size: 0.9rem; font-weight: bold; color: white; background: rgba(0, 0, 0, 0.5);