mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-12-03 04:30:06 +08:00
Formate (#15347)
This commit is contained in:
parent
f65853b2b1
commit
97880a9b47
@ -31,9 +31,11 @@ class SubMenu extends React.Component<SubMenuProps, any> {
|
||||
onKeyDown = (e: React.MouseEvent<HTMLElement>) => {
|
||||
this.subMenu.onKeyDown(e);
|
||||
};
|
||||
|
||||
saveSubMenu = (subMenu: any) => {
|
||||
this.subMenu = subMenu;
|
||||
};
|
||||
|
||||
render() {
|
||||
const { rootPrefixCls, className } = this.props;
|
||||
const theme = this.context.antdMenuTheme;
|
||||
|
@ -157,6 +157,7 @@ class Menu extends React.Component<MenuProps, MenuState> {
|
||||
onMouseEnter(e);
|
||||
}
|
||||
};
|
||||
|
||||
handleTransitionEnd = (e: TransitionEvent) => {
|
||||
// when inlineCollapsed menu width animation finished
|
||||
// https://github.com/ant-design/ant-design/issues/12864
|
||||
@ -169,6 +170,7 @@ class Menu extends React.Component<MenuProps, MenuState> {
|
||||
this.restoreModeVerticalFromInline();
|
||||
}
|
||||
};
|
||||
|
||||
handleClick = (e: ClickParam) => {
|
||||
this.handleOpenChange([]);
|
||||
|
||||
@ -185,6 +187,7 @@ class Menu extends React.Component<MenuProps, MenuState> {
|
||||
onOpenChange(openKeys);
|
||||
}
|
||||
};
|
||||
|
||||
setOpenKeys(openKeys: string[]) {
|
||||
if (!('openKeys' in this.props)) {
|
||||
this.setState({ openKeys });
|
||||
|
Loading…
Reference in New Issue
Block a user