Improve connection error handling (#284)

* feat(WebRTC): enhance connection management with connection failures after X attempts or a certain time

* refactor(WebRTC): simplify WebRTCVideo component and enhance connection error handling

* fix(WebRTC): extend connection timeout from 1 second to 60 seconds for improved error handling
This commit is contained in:
Adam Shiervani
2025-03-24 23:31:23 +01:00
committed by GitHub
parent 0a7847c5ab
commit 5d7d4db4aa
2 changed files with 98 additions and 14 deletions

View File

@@ -47,7 +47,7 @@ export default function WebRTCVideo() {
const hdmiState = useVideoStore(state => state.hdmiState);
const hdmiError = ["no_lock", "no_signal", "out_of_range"].includes(hdmiState);
const isLoading = !hdmiError && !isPlaying;
const isConnectionError = ["error", "failed", "disconnected"].includes(
const isConnectionError = ["error", "failed", "disconnected", "closed"].includes(
peerConnectionState || "",
);