From e24b5e6b7e5d6799e568ee3bc6fff609743392cc Mon Sep 17 00:00:00 2001 From: tobinio Date: Wed, 30 Oct 2024 18:44:38 +0100 Subject: [PATCH] chore: extract SideBar.vue --- app/components/SideBar.vue | 25 +++++++++++++++++++++++++ app/pages/charts.vue | 20 ++++---------------- 2 files changed, 29 insertions(+), 16 deletions(-) create mode 100644 app/components/SideBar.vue diff --git a/app/components/SideBar.vue b/app/components/SideBar.vue new file mode 100644 index 0000000..151d95b --- /dev/null +++ b/app/components/SideBar.vue @@ -0,0 +1,25 @@ + + + + + \ No newline at end of file diff --git a/app/pages/charts.vue b/app/pages/charts.vue index 314a489..b0e6984 100644 --- a/app/pages/charts.vue +++ b/app/pages/charts.vue @@ -68,23 +68,12 @@ const explanation = computed(() => { return useExplanations(stat.value); }); -const sidebarVisible = ref(false); - -onMounted(() => { - const isMediumScreen = useMediaQuery("(min-width: 768px)"); - - if (isMediumScreen.value) { - sidebarVisible.value = true; - } -}); +const sideBarOpen = ref(false);