primevue-mirror/layouts/AppMenu.vue

37 lines
922 B
Vue
Raw Normal View History

<template>
2023-02-28 08:29:30 +00:00
<aside class="layout-sidebar" :class="{ active: active }">
<PrimeVueNuxtLink to="/" class="logo" aria-label="PrimeVue logo"> <img alt="logo" :src="`https://primefaces.org/cdn/primevue/images/primevue-logo${darkTheme ? '-light' : '-dark'}.svg`" /></PrimeVueNuxtLink>
2023-02-28 08:29:30 +00:00
<nav>
<ol class="layout-menu">
<AppMenuItem :menu="menu"></AppMenuItem>
</ol>
</nav>
</aside>
</template>
<script>
2021-03-10 07:51:36 +00:00
import menudata from '@/assets/menu/menu.json';
2023-02-28 08:29:30 +00:00
import AppMenuItem from './AppMenuItem.vue';
export default {
2018-12-26 09:36:00 +00:00
props: {
2023-02-28 08:29:30 +00:00
active: {
type: Boolean,
default: true
}
2018-12-26 09:36:00 +00:00
},
2018-12-06 19:23:02 +00:00
data() {
return {
2023-02-28 08:29:30 +00:00
menu: menudata.data
2022-09-14 14:26:41 +00:00
};
2018-12-06 19:23:02 +00:00
},
2021-07-27 08:59:25 +00:00
computed: {
darkTheme() {
return this.$appState.darkTheme === true;
}
2023-02-28 08:29:30 +00:00
},
components: {
AppMenuItem
2018-12-06 19:23:02 +00:00
}
2022-09-14 14:26:41 +00:00
};
2020-03-31 13:27:54 +00:00
</script>