fix menu-item link, #139

This commit is contained in:
afc163 2015-08-17 17:28:48 +08:00
parent fab3280ed2
commit 662f8889bf
2 changed files with 19 additions and 2 deletions

View File

@ -30,12 +30,15 @@ var App = React.createClass({
<Menu.Item key="app">
<i className="anticon anticon-large"></i>导航二
</Menu.Item>
<SubMenu title={<span><i className="anticon anticon-setting"></i>导航三(子菜单)</span>}>
<SubMenu title={<span><i className="anticon anticon-setting"></i>导航 - 子菜单</span>}>
<Menu.Item key="setting:1">选项1</Menu.Item>
<Menu.Item key="setting:2">选项2</Menu.Item>
<Menu.Item key="setting:3">选项3</Menu.Item>
<Menu.Item key="setting:4">选项4</Menu.Item>
</SubMenu>
<Menu.Item key="alipay">
<a href="http://www.alipay.com/" target="_blank">导航四 - 链接</a>
</Menu.Item>
</Menu>
}
});

View File

@ -156,9 +156,23 @@
& > .@{menuPrefixCls}-item,
& > .@{menuPrefixCls}-submenu > .@{menuPrefixCls}-submenu-title {
padding: 15px 20px;
padding: 0 20px;
line-height: 50px;
position: relative;
top: 1px;
> a {
display: block;
&:before, &:after {
position: absolute;
background-color: rgba(255,255,255,0.001);
width: 20px;
height: 50px;
content: '';
}
&:before {
left: 0;
}
}
}
& > .@{menuPrefixCls}-submenu, & > .@{menuPrefixCls}-item {