From 193852ad6c7a60f0e675b133f7c89a3367969f93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20Andr=C3=A4-Fredsted?= Date: Wed, 20 Mar 2024 15:34:49 +0100 Subject: [PATCH 1/2] fixed issue with cursor not being loaded --- src/components/map/Map.vue | 5 ++++- src/main.js | 6 +++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/components/map/Map.vue b/src/components/map/Map.vue index 8dbf824..493b5b4 100644 --- a/src/components/map/Map.vue +++ b/src/components/map/Map.vue @@ -84,7 +84,10 @@ const inputCoordsChanged = (coords) => { }) overlay.setPosition([coords[0], coords[1]]) - olMap.value.addOverlay(overlay) + //ugly workaround caused by lack of lifecycle coherance between vue components + setTimeout(() => { + olMap.value.addOverlay(overlay) + }, 150) } } diff --git a/src/main.js b/src/main.js index 9ac400d..64fd0ab 100644 --- a/src/main.js +++ b/src/main.js @@ -1,7 +1,7 @@ import -{ createApp} from 'vue' +{ createApp } from 'vue' -import css from '@dataforsyningen/css' +import '@dataforsyningen/css' import store from '@/store' import router from '@/router' import App from './App.vue' @@ -21,7 +21,7 @@ app.config.performance = (import.meta.env.NODE_ENV !== 'production') app.config.globalProperties.$store = store app -.use(css) +.use('@dataforsyningen/css') .use(router) .use(store) From f15fe40f169f9fce25647556bcaddd6b5d5cf4c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20Andr=C3=A4-Fredsted?= Date: Wed, 20 Mar 2024 15:36:23 +0100 Subject: [PATCH 2/2] small syntax refresh --- src/main.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main.js b/src/main.js index 64fd0ab..8624859 100644 --- a/src/main.js +++ b/src/main.js @@ -1,5 +1,4 @@ -import -{ createApp } from 'vue' +import { createApp } from 'vue' import '@dataforsyningen/css' import store from '@/store'