fix menu style

This commit is contained in:
ddcat1115 2017-11-29 11:22:15 +08:00
parent be1cbd4eae
commit eeb642e2bd
4 changed files with 10 additions and 17 deletions

View File

@ -102,12 +102,13 @@ a {
}
// reset menu text color
.ant-menu-item > a {
color: @site-text-color !important;
.menu-site .ant-menu-item > a {
color: @site-text-color;
}
.ant-menu-item-selected > a, .ant-menu-item-selected > a:hover {
color: @primary-color !important;
.menu-site .ant-menu-item-selected > a,
.menu-site .ant-menu-item > a:hover {
color: @primary-color;
}
#react-content {

View File

@ -222,7 +222,7 @@ export default class MainContent extends React.Component {
const menuChild = (
<Menu
inlineIndent="40"
className="aside-container"
className="aside-container menu-site"
mode="inline"
openKeys={this.state.openKeys}
selectedKeys={[activeMenuItem]}

View File

@ -27,14 +27,11 @@ function getStyle() {
position: fixed;
width: 100%;
z-index: 999;
box-shadow: none;
background: rgba(0, 0, 0, 0.25);
border-bottom: 1px solid transparent;
transition: border .5s cubic-bezier(0.455, 0.03, 0.515, 0.955), background .5s cubic-bezier(0.455, 0.03, 0.515, 0.955);
}
#header .header-lang-button {
color: #fff;
border-color: #fff;
}
#header .ant-select-selection,
#header .ant-menu {
background: transparent;
@ -62,11 +59,7 @@ function getStyle() {
border-left-color: #ebedee;
}
.home-nav-white #nav a {
color: rgba(0, 0, 0, 0.65);
}
#header.home-nav-white .header-lang-button:not(:hover) {
color: rgba(0, 0, 0, 0.65);
border-color: #d9d9d9;
color: #314659;
}
#header.home-nav-white .version > .ant-select-selection {
color: rgba(0, 0, 0, 0.65);
@ -85,7 +78,6 @@ function getStyle() {
background: #777;
box-shadow: 0 7px 0 0 #777, 0 14px 0 0 #777;
}
.lang,
.version > .ant-select-selection,
#nav a {
color: #eee;
@ -95,7 +87,7 @@ function getStyle() {
color: #fff;
}
.home-nav-white #nav a.header-link {
color: rgba(0, 0, 0, .65);
color: #314659;
}
#search-box {
border-left-color: rgba(235, 237, 238, .5);

View File

@ -151,7 +151,7 @@ export default class Header extends React.Component {
>
{versionOptions}
</Select>,
<Menu mode={menuMode} selectedKeys={[activeMenuItem]} id="nav" key="nav">
<Menu className="menu-site" mode={menuMode} selectedKeys={[activeMenuItem]} id="nav" key="nav">
<Menu.Item key="home">
<Link to={utils.getLocalizedPathname('/', isZhCN)}>
<FormattedMessage id="app.header.menu.home" />