chore: change menu icon

This commit is contained in:
nebv
2020-10-10 23:09:58 +08:00
parent 67df9b8c93
commit 66b5616957
9 changed files with 1811 additions and 1800 deletions

View File

@@ -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 {