diff --git a/apps/web/src/App.vue b/apps/web/src/App.vue index afe1aa5..9ac58a8 100644 --- a/apps/web/src/App.vue +++ b/apps/web/src/App.vue @@ -6,6 +6,7 @@ import { useAuthStore } from "./stores/auth"; const auth = useAuthStore(); const reconnecting = ref(false); +const preventDoubleTapZoom = (event: MouseEvent) => event.preventDefault(); const retrySession = async () => { if (reconnecting.value || (typeof navigator !== "undefined" && !navigator.onLine)) return; reconnecting.value = true; @@ -17,8 +18,14 @@ const retrySession = async () => { }; const handleOnline = () => void retrySession(); -onMounted(() => window.addEventListener("online", handleOnline)); -onBeforeUnmount(() => window.removeEventListener("online", handleOnline)); +onMounted(() => { + window.addEventListener("online", handleOnline); + window.addEventListener("dblclick", preventDoubleTapZoom, { passive: false }); +}); +onBeforeUnmount(() => { + window.removeEventListener("online", handleOnline); + window.removeEventListener("dblclick", preventDoubleTapZoom); +});