|
|
|
@menu-prefix-cls: ~"@{css-prefix}menu";
|
|
|
|
|
|
|
|
// default theme
|
|
|
|
.@{menu-prefix-cls} {
|
|
|
|
outline: none;
|
|
|
|
margin-bottom: 0;
|
|
|
|
padding-left: 0; // Override default ul/ol
|
|
|
|
list-style: none;
|
|
|
|
z-index: 999;
|
|
|
|
box-shadow: @overlay-shadow;
|
|
|
|
color: @text-color;
|
|
|
|
background: #fff;
|
|
|
|
|
|
|
|
&-hidden {
|
|
|
|
display: none;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-item-group-list {
|
|
|
|
margin: 0;
|
|
|
|
padding: 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-item-group-title {
|
|
|
|
color: #999;
|
|
|
|
line-height: 1.5;
|
|
|
|
padding: 8px 10px;
|
|
|
|
border-bottom: 1px solid #dedede;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-item,
|
|
|
|
&-submenu-title {
|
|
|
|
cursor: pointer;
|
|
|
|
transition: all 0.3s ease;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-item-active,
|
|
|
|
&-submenu-title:hover {
|
|
|
|
background-color: tint(@primary-color, 90%);
|
|
|
|
}
|
|
|
|
|
|
|
|
&-horizontal > &-item-active,
|
|
|
|
&-horizontal > &-submenu &-submenu-title:hover {
|
|
|
|
background-color: transparent;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-item-selected {
|
|
|
|
color: @primary-color;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-inline,
|
|
|
|
&-vertical {
|
|
|
|
border-right: 1px solid #e9e9e9;
|
|
|
|
.@{menu-prefix-cls}-item {
|
|
|
|
border-right: 2px solid transparent;
|
|
|
|
margin-left: -1px;
|
|
|
|
left: 1px;
|
|
|
|
position: relative;
|
|
|
|
z-index: 1;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&-inline {
|
|
|
|
.@{menu-prefix-cls}-selected,
|
|
|
|
.@{menu-prefix-cls}-item-selected {
|
|
|
|
border-right: 2px solid @primary-color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&-submenu-horizontal > .@{menu-prefix-cls} {
|
|
|
|
top: 100%;
|
|
|
|
left: 0;
|
|
|
|
position: absolute;
|
|
|
|
min-width: 100%;
|
|
|
|
margin-top: 7px;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-submenu-vertical > .@{menu-prefix-cls} {
|
|
|
|
top: 0;
|
|
|
|
left: 100%;
|
|
|
|
position: absolute;
|
|
|
|
min-width: 160px;
|
|
|
|
margin-left: 4px;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-item, &-submenu-title {
|
|
|
|
margin: 0;
|
|
|
|
position: relative;
|
|
|
|
display: block;
|
|
|
|
white-space: nowrap;
|
|
|
|
|
|
|
|
// Disabled state sets text to gray and nukes hover/tab effects
|
|
|
|
&.@{menu-prefix-cls}-item-disabled, &.@{menu-prefix-cls}-submenu-disabled {
|
|
|
|
color: #999 !important;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
& > &-item-divider {
|
|
|
|
height: 1px;
|
|
|
|
margin: 1px 0;
|
|
|
|
overflow: hidden;
|
|
|
|
padding: 0;
|
|
|
|
line-height: 0;
|
|
|
|
background-color: #e5e5e5;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-submenu {
|
|
|
|
position: relative;
|
|
|
|
|
|
|
|
> .@{menu-prefix-cls} {
|
|
|
|
background-color: #fff;
|
|
|
|
border-radius: 4px;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-vertical > .@{menu-prefix-cls}-submenu-title:after {
|
|
|
|
font-family: "anticon" !important;
|
|
|
|
font-style: normal;
|
|
|
|
vertical-align: baseline;
|
|
|
|
text-align: center;
|
|
|
|
text-transform: none;
|
|
|
|
text-rendering: auto;
|
|
|
|
position: absolute;
|
|
|
|
transition: transform .3s ease;
|
|
|
|
content: "\e603";
|
|
|
|
right: 16px;
|
|
|
|
.ie-rotate(3);
|
|
|
|
transform: rotate(270deg) scale(0.75);
|
|
|
|
}
|
|
|
|
|
|
|
|
&-inline > .@{menu-prefix-cls}-submenu-title:after {
|
|
|
|
font-family: "anticon" !important;
|
|
|
|
font-style: normal;
|
|
|
|
vertical-align: baseline;
|
|
|
|
text-align: center;
|
|
|
|
text-transform: none;
|
|
|
|
text-rendering: auto;
|
|
|
|
position: absolute;
|
|
|
|
transition: transform .3s ease;
|
|
|
|
content: "\e603";
|
|
|
|
right: 16px;
|
|
|
|
top: 0;
|
|
|
|
.iconfont-size-under-12px(8px);
|
|
|
|
}
|
|
|
|
|
|
|
|
&-open {
|
|
|
|
&.@{menu-prefix-cls}-submenu-inline > .@{menu-prefix-cls}-submenu-title:after {
|
|
|
|
.ie-rotate(1);
|
|
|
|
transform: rotate(180deg) scale(0.75);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.@{menu-prefix-cls}-submenu-title, .@{menu-prefix-cls}-item {
|
|
|
|
.anticon {
|
|
|
|
width: 14px;
|
|
|
|
margin-right: 8px;
|
|
|
|
top: 1px;
|
|
|
|
color: #999;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&-horizontal {
|
|
|
|
border: none;
|
|
|
|
border-bottom: 1px solid #d9d9d9;
|
|
|
|
box-shadow: none;
|
|
|
|
padding-left: 20px;
|
|
|
|
z-index: 0;
|
|
|
|
|
|
|
|
& > .@{menu-prefix-cls}-item,
|
|
|
|
& > .@{menu-prefix-cls}-submenu {
|
|
|
|
padding: 0 20px;
|
|
|
|
line-height: 50px;
|
|
|
|
position: relative;
|
|
|
|
top: 1px;
|
|
|
|
> a , > span{
|
|
|
|
line-height: 51px;
|
|
|
|
}
|
|
|
|
> a {
|
|
|
|
display: block;
|
|
|
|
color: @text-color;
|
|
|
|
&:hover {
|
|
|
|
color: @primary-color;
|
|
|
|
}
|
|
|
|
&:before, &:after {
|
|
|
|
position: absolute;
|
|
|
|
background-color: transparent;
|
|
|
|
width: 20px;
|
|
|
|
height: 50px;
|
|
|
|
content: '';
|
|
|
|
}
|
|
|
|
&:before {
|
|
|
|
left: 0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
& > .@{menu-prefix-cls}-submenu, & > .@{menu-prefix-cls}-item {
|
|
|
|
float: left;
|
|
|
|
border-bottom: 2px solid transparent;
|
|
|
|
margin-right: 20px;
|
|
|
|
|
|
|
|
&-active,
|
|
|
|
&-selected {
|
|
|
|
border-bottom: 2px solid @primary-color;
|
|
|
|
color: @primary-color;
|
|
|
|
.anticon {
|
|
|
|
color: @primary-color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&:after {
|
|
|
|
content: "\20";
|
|
|
|
display: block;
|
|
|
|
height: 0;
|
|
|
|
clear: both;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&-vertical, &-inline {
|
|
|
|
& > .@{menu-prefix-cls}-item, & > .@{menu-prefix-cls}-submenu > .@{menu-prefix-cls}-submenu-title {
|
|
|
|
padding: 0 20px;
|
|
|
|
font-size: 12px;
|
|
|
|
line-height: 42px;
|
|
|
|
height: 42px;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&-vertical&-sub {
|
|
|
|
padding: 0;
|
|
|
|
transform-origin: 0 0;
|
|
|
|
& > .@{menu-prefix-cls}-item, & > .@{menu-prefix-cls}-submenu {
|
|
|
|
transform-origin: 0 0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&-root&-vertical,
|
|
|
|
&-root&-inline {
|
|
|
|
box-shadow: none;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-sub&-inline {
|
|
|
|
padding: 0;
|
|
|
|
border: none;
|
|
|
|
box-shadow: none;
|
|
|
|
border-radius: 0;
|
|
|
|
& > .@{menu-prefix-cls}-item, & > .@{menu-prefix-cls}-submenu > .@{menu-prefix-cls}-submenu-title {
|
|
|
|
line-height: 34px;
|
|
|
|
height: 34px;
|
|
|
|
list-style-type: disc;
|
|
|
|
list-style-position: inside;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.@{menu-prefix-cls}-submenu-title, .@{menu-prefix-cls}-item {
|
|
|
|
.anticon {
|
|
|
|
width: 14px;
|
|
|
|
margin-right: 8px;
|
|
|
|
top: 1px;
|
|
|
|
}
|
|
|
|
}
|