From 51aa070b3044074a394a9b7123a64dc22c2489b4 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Fri, 17 Apr 2026 02:58:43 +0200 Subject: [PATCH] fix(ui-web): use portable WebSocketReadyState in CSData isWebSocketOpen Replace browser-specific WebSocket.OPEN with WebSocketReadyState.OPEN from ui-common for environment portability. --- ui/web/src/components/charging-stations/CSData.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ui/web/src/components/charging-stations/CSData.vue b/ui/web/src/components/charging-stations/CSData.vue index 6420c007..1aa169d8 100644 --- a/ui/web/src/components/charging-stations/CSData.vue +++ b/ui/web/src/components/charging-stations/CSData.vue @@ -121,6 +121,7 @@ import { type ConnectorEntry, getWebSocketStateName, type Status, + WebSocketReadyState, } from 'ui-common' import { computed } from 'vue' import { useToast } from 'vue-toast-notification' @@ -143,7 +144,7 @@ const props = defineProps<{ const $emit = defineEmits(['need-refresh']) -const isWebSocketOpen = computed(() => props.chargingStation.wsState === WebSocket.OPEN) +const isWebSocketOpen = computed(() => props.chargingStation.wsState === WebSocketReadyState.OPEN) const getConnectorEntries = (): ConnectorEntry[] => { if (Array.isArray(props.chargingStation.evses) && props.chargingStation.evses.length > 0) { -- 2.53.0