This commit is contained in:
NoriDev 2023-06-15 00:05:24 +09:00
parent e45ae000ed
commit 2250dafb09

View file

@ -62,7 +62,6 @@ import { i18n } from '@/i18n';
import { definePageMetadata } from '@/scripts/page-metadata';
import { eventBus } from '@/scripts/cherrypick/eventBus';
import { deepClone } from '@/scripts/clone';
import {MenuItem} from "@/types/menu";
const Sortable = defineAsyncComponent(() => import('vuedraggable').then(x => x.default));
@ -86,7 +85,7 @@ async function reloadAsk() {
} else eventBus.emit('hasRequireRefresh', true);
}
async function addItem(e: MouseEvent) {
async function addItem(ev: MouseEvent) {
const menu = Object.keys(navbarItemDef).filter(k => !defaultStore.state.menu.includes(k));
os.popupMenu([
...menu.map(k => ({
@ -111,7 +110,7 @@ async function addItem(e: MouseEvent) {
}];
},
},
], e.target || e.currentTarget);
], ev.target || ev.currentTarget);
}
function removeItem(index: number) {