diff --git a/components/app-header.vue b/components/app-header.vue index e0326aa1..edaf7e97 100644 --- a/components/app-header.vue +++ b/components/app-header.vue @@ -16,16 +16,26 @@ const defaultLinks = computed< if (!project.map.startPage) { return { home: { href: { path: "/" }, label: t("AppHeader.links.home") }, - data: { href: { path: "/data" }, label: t("AppHeader.links.data") }, - map: { href: { path: "/map" }, label: t("AppHeader.links.map") }, - network: { href: { path: "/network" }, label: t("AppHeader.links.network") }, + data: { + href: { path: "/visualization", query: { mode: "table" } }, + label: t("AppHeader.links.data"), + }, + map: { + href: { path: "/visualization", query: { mode: "map" } }, + label: t("AppHeader.links.map"), + }, + network: { + href: { path: "/visualization", query: { mode: "network" } }, + label: t("AppHeader.links.network"), + }, team: { href: { path: "/team" }, label: t("AppHeader.links.team") }, }; } return { - home: { href: { path: "/" }, label: t("AppHeader.links.home") }, - data: { href: { path: "/data" }, label: t("AppHeader.links.data") }, - network: { href: { path: "/network" }, label: t("AppHeader.links.network") }, + home: { + href: { path: "/", query: { mode: "map" } }, + label: t("AppHeader.links.home"), + }, team: { href: { path: "/team" }, label: t("AppHeader.links.team") }, }; }); diff --git a/components/custom-primary-details-feature.vue b/components/custom-primary-details-feature.vue index b968753e..0d8c13f7 100644 --- a/components/custom-primary-details-feature.vue +++ b/components/custom-primary-details-feature.vue @@ -6,6 +6,7 @@ const t = useTranslations(); const { getUnprefixedId } = useIdPrefix(); const props = defineProps<{ entity: EntityFeature }>(); +const route = useRoute(); const { data } = useGetBySystemClass( computed(() => { @@ -80,13 +81,27 @@ const handledRelations: Array = [ onMounted(() => { emit("handledRelations", handledRelations); }); + +function getPath() { + if (route.path.includes("visualization")) { + return "visualization"; + } + return ""; +} + +const currentMode = computed(() => { + return route.query.mode; +});