UNPKG

zent

Version:

一套前端设计语言和基于React的实现

32 lines (31 loc) 974 B
import { Component } from 'react'; export interface IMenuListItem { value?: any; content?: React.ReactNode; isGroup?: boolean; isDivider?: boolean; onClick?: React.MouseEventHandler<HTMLLIElement>; icon?: string; disabled?: string; active?: boolean | ((val: any) => boolean); hoverable?: boolean; className?: string; } export interface IMenuListItemProps { item: IMenuListItem; index: number; hover: boolean; focusTo: (focusIdx: number | null, autoScroll?: boolean) => void; onRequestClose: () => void; } export declare class MenuListItem extends Component<IMenuListItemProps> { onClick: (e: React.MouseEvent<HTMLLIElement>) => void; onMouseEnter: () => void; onMouseLeave: () => void; render(): JSX.Element; } export declare function handleItemClick({ event, item, onRequestClose, }: { event: React.MouseEvent<HTMLLIElement>; item: IMenuListItem; onRequestClose: () => void; }): void;