From 8e37650fd8aa435ad5aac13d7f8045a336449e6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20H=C3=B8vik?= <andehovi@stud.ntnu.no> Date: Fri, 26 Apr 2024 10:57:17 +0200 Subject: [PATCH] Fixed error in configuration --- src/components/Configuration/Configuration.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/Configuration/Configuration.vue b/src/components/Configuration/Configuration.vue index a02e631..4f52d07 100644 --- a/src/components/Configuration/Configuration.vue +++ b/src/components/Configuration/Configuration.vue @@ -15,9 +15,10 @@ let percentage = ref(1/length); router.push(Object.keys(configurationSteps)[0]) let currentRoute = useRoute() let currentPath = currentRoute.fullPath +type ConfigurationStepPath = keyof typeof configurationSteps; // Sets the current path to a new path and updates progressbar -const onNewRouteEvent = (path: string) => { +const onNewRouteEvent = (path: ConfigurationStepPath) => { currentPath = path percentage.value = (1/length) * configurationSteps[path] } -- GitLab