mirror of
https://gitee.com/ant-design-vue/ant-design-vue.git
synced 2024-12-03 04:27:41 +08:00
feat: menu event args add item #4290
This commit is contained in:
parent
9a86d1b54d
commit
0c3d9d535d
@ -94,6 +94,10 @@ export default defineComponent({
|
||||
keyPath: keysPath.value,
|
||||
eventKeyPath: [...parentEventKeys.value, eventKey],
|
||||
domEvent: e,
|
||||
item: {
|
||||
...props,
|
||||
...attrs,
|
||||
},
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -1,4 +1,5 @@
|
||||
import type { Key } from '../../_util/type';
|
||||
import type { MenuItemProps } from './MenuItem';
|
||||
|
||||
export type MenuTheme = 'light' | 'dark';
|
||||
|
||||
@ -24,6 +25,7 @@ export interface MenuInfo {
|
||||
keyPath?: Key[];
|
||||
eventKeyPath: string[];
|
||||
domEvent: MouseEvent | KeyboardEvent;
|
||||
item: MenuItemProps & { [key: string]: any };
|
||||
}
|
||||
|
||||
export interface MenuTitleInfo {
|
||||
|
@ -7,8 +7,8 @@ import addEventListener from '../vc-util/Dom/addEventListener';
|
||||
import { getConfirmLocale } from './locale';
|
||||
import CloseOutlined from '@ant-design/icons-vue/CloseOutlined';
|
||||
import Button from '../button';
|
||||
import type { ButtonProps as ButtonPropsType } from '../button/buttonTypes';
|
||||
import buttonTypes, { ButtonType } from '../button/buttonTypes';
|
||||
import type { ButtonProps as ButtonPropsType, ButtonType } from '../button/buttonTypes';
|
||||
import buttonTypes from '../button/buttonTypes';
|
||||
import LocaleReceiver from '../locale-provider/LocaleReceiver';
|
||||
import { getComponent, getSlot } from '../_util/props-util';
|
||||
import initDefaultProps from '../_util/props-util/initDefaultProps';
|
||||
|
Loading…
Reference in New Issue
Block a user