跳到主要内容

eo-directory

<eo-directory>

构件 eo-directory

Examples

Basic

Playground

Properties

NameDescriptionTypeDefaultRequired
position

设置定位方式:静态定位或固定定位。

"static" | "fixed" "fixed"
directoryTitle

目录标题

string
menuItems

菜单数据

MenuItem[] []
hideRightBorder

是否隐藏右边线

boolean false
suffixBrick

后缀 useBrick

{ useBrick: UseBrickConf }
defaultSelectedKeys

默认选中高亮的菜单项

string[]

Events

NameDescriptionEvent Detail
menu.item.click

菜单点击,groupKey 表示对应分组的key,data 表示对应菜单项

MenuItemClickEventDetail - { groupKey: string, data: MenuChildrenItem }
suffix.icon.click

点击icon,detail为 对应菜单项或者是分组的key

{ key: string } - { key: string }

Type references

MenuItem

NameTypeRequiredDescription
titlestring
keystring
type"group" | "item"
childrenMenuChildrenItem[]
suffixIconGeneralIconProps
suffixIconTooltipstring
suffixIconDisabledboolean

MenuChildrenItem

NameTypeRequiredDescription
titlestring
keystring
[key: string]any

MenuItemClickEventDetail

NameTypeRequiredDescription
dataMenuChildrenItem
groupKeystring