rm nocache

This commit is contained in:
tamaina 2023-08-06 12:41:53 +00:00
parent 89c245c5e4
commit fb924e6dc3
2 changed files with 2 additions and 4 deletions

View File

@ -167,9 +167,7 @@ async function showChildren(item: MenuParent, ev: MouseEvent) {
}
})();
if (!item.noCache) {
childrenCache.set(item, children);
}
childrenCache.set(item, children);
if (props.asDrawer) {
os.popupMenu(children, ev.currentTarget ?? ev.target).finally(() => {

View File

@ -16,7 +16,7 @@ export type MenuA = { type: 'a', href: string, target?: string, download?: strin
export type MenuUser = { type: 'user', user: Misskey.entities.User, active?: boolean, indicate?: boolean, action: MenuAction };
export type MenuSwitch = { type: 'switch', ref: Ref<boolean>, text: string, disabled?: boolean };
export type MenuButton = { type?: 'button', text: string, icon?: string, indicate?: boolean, danger?: boolean, active?: boolean, avatar?: Misskey.entities.User; action: MenuAction };
export type MenuParent = { type: 'parent', text: string, icon?: string, noCache?: boolean, children: MenuItem[] | (() => Promise<MenuItem[]> | MenuItem[]) };
export type MenuParent = { type: 'parent', text: string, icon?: string, children: MenuItem[] | (() => Promise<MenuItem[]> | MenuItem[]) };
export type MenuPending = { type: 'pending' };