diff --git a/src/ws_sansad.rs b/src/ws_sansad.rs index 51b6c35..8475b53 100644 --- a/src/ws_sansad.rs +++ b/src/ws_sansad.rs @@ -11,11 +11,11 @@ use crate::{chat_pinnd::ChatPinnd, messages as ms, validator::{Validation as vl, /// How often heartbeat pings are sent const HEARTBEAT_INTERVAL: Duration = Duration::from_secs(5); /// How long before lack of client response causes a timeout -const CLIENT_TIMEOUT: Duration = Duration::from_secs(10); +const CLIENT_TIMEOUT: Duration = Duration::from_secs(15); // for phones if browser kept websocket on const SPECIAL_HEARTBEAT_INTERVAL: Duration = Duration::from_secs(5*60); -const SPECIAL_CLIENT_TIMEOUT: Duration = Duration::from_secs(6*60); +const SPECIAL_CLIENT_TIMEOUT: Duration = Duration::from_secs(10*60); pub struct WsSansad { kunjika: String, diff --git a/static/index.html b/static/index.html index 7e9e5a9..14ebeae 100644 --- a/static/index.html +++ b/static/index.html @@ -49,7 +49,7 @@
-
Connect
+
Connect
@@ -70,7 +70,7 @@
-
Connect
+
Connect
diff --git a/static/js/app.js b/static/js/app.js index 9c3c17d..4a0c406 100644 --- a/static/js/app.js +++ b/static/js/app.js @@ -63,6 +63,10 @@ $(document).ready(() => { $('#selected_clip').css('bottom', (this.scrollHeight + 10) + 'px'); } }); + + $('[name=connect]').click(function () { + connect($(this).parents('form').first()); + }); }); function sendTyping() {