diff --git a/ui/minimal/index.html b/ui/minimal/index.html
index 36ffb37..8c16c21 100644
--- a/ui/minimal/index.html
+++ b/ui/minimal/index.html
@@ -1101,6 +1101,7 @@
const r = JSON.parse(e.data);
if (r.type === "connected") {
console.log("WebSocket welcome message:", r);
+ reconnectAttempts = 0;
return;
}
if (r.bot_id) {
@@ -1154,7 +1155,6 @@
ws.readyState,
);
updateConnectionStatus("connected");
- reconnectAttempts = 0;
hasReceivedInitialMessage = false;
};
ws.onclose = function (e) {
diff --git a/ui/suite/attendant/attendant.js b/ui/suite/attendant/attendant.js
index bae3a54..94bc6ac 100644
--- a/ui/suite/attendant/attendant.js
+++ b/ui/suite/attendant/attendant.js
@@ -1322,7 +1322,6 @@
"WebSocket connected for attendant:",
currentAttendantId,
);
- reconnectAttempts = 0;
showToast(
"Connected to notification service",
"success",
@@ -1367,6 +1366,7 @@
switch (msgType) {
case "connected":
console.log("WebSocket connected:", data.message);
+ reconnectAttempts = 0;
break;
case "new_conversation":
showToast("New conversation in queue", "info");
diff --git a/ui/suite/chat/chat.html b/ui/suite/chat/chat.html
index 0f066f3..c9a42df 100644
--- a/ui/suite/chat/chat.html
+++ b/ui/suite/chat/chat.html
@@ -886,7 +886,6 @@
ws.onopen = function () {
clearTimeout(connectionTimeout);
console.log("WebSocket connected to:", url);
- reconnectAttempts = 0;
disconnectNotified = false;
updateConnectionStatus("connected");
};
@@ -897,7 +896,10 @@
console.log("Chat WebSocket received:", data);
// Ignore connection confirmation
- if (data.type === "connected") return;
+ if (data.type === "connected") {
+ reconnectAttempts = 0;
+ return;
+ }
// Process system events (theme changes, etc)
if (data.event) {
diff --git a/ui/suite/desktop.html b/ui/suite/desktop.html
index 0b57511..5980c22 100644
--- a/ui/suite/desktop.html
+++ b/ui/suite/desktop.html
@@ -14,6 +14,7 @@
+