mirror of
https://github.com/vbenjs/vue-vben-admin.git
synced 2025-08-27 19:29:04 +08:00
chore: change menu icon
This commit is contained in:
@@ -29,16 +29,13 @@ export function useOpenKeys(
|
||||
|
||||
function handleOpenChange(openKeys: string[]) {
|
||||
const rootSubMenuKeys: string[] = [];
|
||||
for (const menu of unref(menus)) {
|
||||
const { children, path } = menu;
|
||||
for (const { children, path } of unref(menus)) {
|
||||
if (children && children.length > 0) {
|
||||
rootSubMenuKeys.push(path);
|
||||
}
|
||||
}
|
||||
|
||||
if (!menuStore.getCollapsedState || !unref(isAppMenu)) {
|
||||
const latestOpenKey = openKeys.find((key) => menuState.openKeys.indexOf(key) === -1);
|
||||
|
||||
if (rootSubMenuKeys.indexOf(latestOpenKey as string) === -1) {
|
||||
menuState.openKeys = openKeys;
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user