Add menu button for opening the settings

This commit is contained in:
2022-04-30 23:08:29 +02:00
parent a7a505b694
commit 8c64568077
3 changed files with 22 additions and 2 deletions

View File

@ -1,7 +1,7 @@
<script setup>
import MenuIcon from "./icons/menu-icon.vue";
import { computed } from "vue";
import { useRoute } from "vue-router";
import { useRoute, RouterLink } from "vue-router";
const route = useRoute();
const routeName = computed(() => route.name);
@ -11,7 +11,9 @@ const routeName = computed(() => route.name);
<div class="titlebar">
<span class="title">{{ routeName }}</span>
<div class="settings">
<MenuIcon />
<RouterLink to="/settings">
<MenuIcon />
</RouterLink>
</div>
</div>
</template>
@ -38,4 +40,16 @@ const routeName = computed(() => route.name);
justify-content: right;
padding-right: 13px;
}
a {
display: inherit;
text-decoration: none;
color: inherit;
padding: 4px;
}
a.router-link-active {
background-color: #335723;
border-radius: 5px;
}
</style>