Revert "fix(menu): need router props (#589)" (#590)

This reverts commit 0c0ba082b4.
This commit is contained in:
PY 2023-08-15 22:17:54 +08:00 committed by GitHub
parent 0c0ba082b4
commit f1853ad3a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8,7 +8,7 @@
</template>
{{ item.title }}
</t-menu-item>
<t-menu-item v-else :name="item.path" :value="getPath(item)" :to="item.path" :router="router">
<t-menu-item v-else :name="item.path" :value="getPath(item)" :to="item.path">
<template #icon>
<component :is="menuIcon(item)" class="t-icon"></component>
</template>
@ -27,15 +27,12 @@
<script setup lang="tsx">
import type { PropType } from 'vue';
import { computed } from 'vue';
import { useRouter } from 'vue-router';
import { getActive } from '@/router';
import type { MenuRoute } from '@/types/interface';
type ListItemType = MenuRoute & { icon?: string };
const router = useRouter();
const props = defineProps({
navData: {
type: Array as PropType<MenuRoute[]>,