fix(menu): refactor menu system to use pure config objects and fix submenu click events
This commit is contained in:
14
src/components/menu/item.ts
Normal file
14
src/components/menu/item.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
/**
|
||||
* 菜单项配置接口 (用于简化的对象配置)
|
||||
*/
|
||||
export interface MenuItemConfig {
|
||||
id: string;
|
||||
label: string;
|
||||
onClick?: () => void;
|
||||
icon?: string;
|
||||
group?: string;
|
||||
order?: number;
|
||||
children?: MenuItemConfig[];
|
||||
disabled?: boolean;
|
||||
visible?: boolean;
|
||||
}
|
||||
Reference in New Issue
Block a user