diff --git a/app/src/modules/insights/routes/dashboard.vue b/app/src/modules/insights/routes/dashboard.vue index c7f044eb65..6cb8acf66b 100644 --- a/app/src/modules/insights/routes/dashboard.vue +++ b/app/src/modules/insights/routes/dashboard.vue @@ -192,7 +192,12 @@ export default defineComponent({ const zoomToFit = ref(false); watch(editMode, (editModeEnabled) => { - if (editModeEnabled) zoomToFit.value = false; + if (editModeEnabled) { + zoomToFit.value = false; + window.onbeforeunload = () => ''; + } else { + window.onbeforeunload = null; + } }); const currentDashboard = computed(() =>