Browse Source

Fixes for inverted menus, changes to active styles

pull/2034/head
jlukic 10 years ago
parent
commit
0db9045878
2 changed files with 33 additions and 139 deletions
  1. 135
      src/definitions/collections/menu.less
  2. 37
      src/themes/default/collections/menu.variables

135
src/definitions/collections/menu.less

@ -550,110 +550,12 @@ Floated Menu / Item
border-left: none; border-left: none;
} }
.ui.vertical.menu .item .menu .active.item { .ui.vertical.menu .item .menu .active.item {
box-shadow: none;
background-color: @subMenuActiveBackground; background-color: @subMenuActiveBackground;
font-weight: @subMenuActiveFontWeight; font-weight: @subMenuActiveFontWeight;
color: @subMenuActiveTextColor; color: @subMenuActiveTextColor;
} }
/*--------------
Tiered
---------------*/
.ui.tiered.menu {
flex-wrap: wrap;
}
.ui.tiered.menu > .menu {
width: 100%;
}
.ui.tiered.menu > .menu > .item:hover {
color: @tieredSubMenuActiveColor;
}
.ui.tiered.menu .active.item {
background: @tieredActiveItemBackground;
}
.ui.tiered.menu > .menu .item.active:after {
position: absolute;
content: '';
margin-top: -@dividerSize;
top: 100%;
left: 0px;
width: 100%;
height: 2px;
background-color: @tieredActiveMenuBackground;
}
/* Sub Menu */
.ui.tiered.menu .sub.menu {
background-color: @tieredActiveMenuBackground;
border-radius: 0em 0em @borderRadius @borderRadius;
border-top: 1px solid @borderColor;
box-shadow: none;
}
.ui.tiered.menu > .sub.menu > .item {
color: @tieredSubMenuColor;
font-weight: @tieredSubMenuFontWeight;
text-transform: @tieredSubMenuTextTransform;
font-size: @subMenuFontSize;
}
/* Sub Menu Divider */
.ui.tiered.menu .sub.menu .item:before {
background: none;
}
/* Sub Menu Hover */
.ui.tiered.menu .sub.menu .item:hover {
background: @tieredSubMenuHoverBackground;
color: @tieredSubMenuHoverColor;
}
/* Sub Menu Active */
.ui.tiered.menu .sub.menu .active.item {
padding-top: @itemVerticalPadding;
background: @tieredSubMenuActiveBackground;
border-radius: 0;
border-top: medium none;
box-shadow: none;
color: @tieredSubMenuActiveColor !important;
}
.ui.tiered.menu .sub.menu .active.item:after {
display: none;
}
/* Inverted Tiered Menu */
.ui.inverted.tiered.menu > .menu > .item {
color: @invertedUnselectedTextColor;
}
.ui.inverted.tiered.menu .sub.menu {
background-color: @tieredInvertedSubMenuBackground;
}
.ui.inverted.tiered.menu .sub.menu .item {
color: @invertedLightTextColor;
}
.ui.inverted.tiered.menu > .menu > .item:hover {
color: @invertedHoveredTextColor;
}
.ui.inverted.tiered.menu .active.item:after {
display: none;
}
.ui.inverted.tiered.menu > .sub.menu > .active.item,
.ui.inverted.tiered.menu > .menu > .active.item {
color: @invertedSelectedTextColor !important;
box-shadow: none;
}
/* Tiered Pointing */
.ui.pointing.tiered.menu > .menu > .item:after {
display: none;
}
.ui.pointing.tiered.menu > .sub.menu > .item:after {
display: block;
}
/*-------------- /*--------------
Tabular Tabular
---------------*/ ---------------*/
@ -839,14 +741,15 @@ Floated Menu / Item
/* Inverted */ /* Inverted */
.ui.secondary.inverted.menu .link.item, .ui.secondary.inverted.menu .link.item,
.ui.secondary.inverted.menu a.item { .ui.secondary.inverted.menu a.item {
color: @secondaryInvertedColor;
color: @secondaryInvertedColor !important;
} }
.ui.secondary.inverted.menu .dropdown.item:hover, .ui.secondary.inverted.menu .dropdown.item:hover,
.ui.secondary.inverted.menu .link.item:hover, .ui.secondary.inverted.menu .link.item:hover,
.ui.secondary.inverted.menu a.item:hover { .ui.secondary.inverted.menu a.item:hover {
color: @secondaryInvertedHoverColor;
color: @secondaryInvertedHoverColor !important;
} }
.ui.secondary.inverted.menu .active.item { .ui.secondary.inverted.menu .active.item {
color: @secondaryInvertedActiveColor !important;
background-color: @secondaryInvertedActiveBackground; background-color: @secondaryInvertedActiveBackground;
} }
@ -1285,11 +1188,6 @@ Floated Menu / Item
.ui.inverted.menu .item:before { .ui.inverted.menu .item:before {
background: @invertedDividerBackground; background: @invertedDividerBackground;
} }
.ui.inverted.menu .dropdown.item:hover:before,
.ui.inverted.menu .link.item:hover:before,
.ui.inverted.menu a.item:hover:before {
background: none;
}
.ui.vertical.inverted.menu .item:before { .ui.vertical.inverted.menu .item:before {
background: @invertedVerticalDividerBackground; background: @invertedVerticalDividerBackground;
} }
@ -1329,8 +1227,6 @@ Floated Menu / Item
background: @invertedSubMenuBackground; background: @invertedSubMenuBackground;
color: @invertedSubMenuHoverColor; color: @invertedSubMenuHoverColor;
} }
/*--- Pressed ---*/ /*--- Pressed ---*/
.ui.inverted.menu a.item:active, .ui.inverted.menu a.item:active,
.ui.inverted.menu .link.item:active, .ui.inverted.menu .link.item:active,
@ -1341,7 +1237,6 @@ Floated Menu / Item
/*--- Active ---*/ /*--- Active ---*/
.ui.inverted.menu .active.item { .ui.inverted.menu .active.item {
box-shadow: none !important;
background: @invertedActiveBackground; background: @invertedActiveBackground;
color: @invertedActiveColor !important; color: @invertedActiveColor !important;
} }
@ -1349,19 +1244,18 @@ Floated Menu / Item
background: @invertedSubMenuActiveBackground; background: @invertedSubMenuActiveBackground;
color: @invertedSubMenuActiveColor; color: @invertedSubMenuActiveColor;
} }
/*--- Pointers ---*/
.ui.inverted.pointing.menu .item:hover:after {
background: @invertedArrowHoverColor;
box-shadow: none;
}
.ui.inv
.ui.inverted.pointing.menu .active.item:after { .ui.inverted.pointing.menu .active.item:after {
background: @invertedArrowActiveColor;
box-shadow: none;
background: @invertedArrowActiveColor !important;
box-shadow: none !important;
}
/*--- Active Hover ---*/
.ui.inverted.menu .active.item:hover {
background: @invertedActiveHoverBackground;
color: @invertedActiveHoverColor !important;
} }
.ui.inverted.pointing.menu .active.item:hover:after { .ui.inverted.pointing.menu .active.item:hover:after {
background: @invertedArrowActiveHoverColor;
background: @invertedArrowActiveHoverColor !important;
} }
@ -1408,11 +1302,6 @@ Floated Menu / Item
Inverted Colors Inverted Colors
---------------*/ ---------------*/
/*--- Light Colors ---*/
.ui.grey.menu {
background-color: @offWhite;
}
/*--- Inverted Colors ---*/ /*--- Inverted Colors ---*/
/* Blue */ /* Blue */

37
src/themes/default/collections/menu.variables

@ -155,10 +155,6 @@
@arrowActiveColor: #F7F7F7; @arrowActiveColor: #F7F7F7;
@arrowActiveHoverColor: @arrowHoverColor; @arrowActiveHoverColor: @arrowHoverColor;
@invertedArrowHoverColor: #5B5B5B;
@invertedArrowActiveColor: #4A4A4A;
@invertedArrowActiveHoverColor: @invertedArrowHoverColor;
@arrowVerticalHoverColor: @arrowHoverColor; @arrowVerticalHoverColor: @arrowHoverColor;
@arrowVerticalActiveColor: @arrowActiveColor; @arrowVerticalActiveColor: @arrowActiveColor;
@arrowVerticalSubMenuColor: @white; @arrowVerticalSubMenuColor: @white;
@ -179,7 +175,7 @@
/* Active Item */ /* Active Item */
@activeItemBackground: @subtleTransparentBlack; @activeItemBackground: @subtleTransparentBlack;
@activeItemTextColor: @selectedTextColor; @activeItemTextColor: @selectedTextColor;
@activeItemFontWeight: @itemFontWeight;
@activeItemFontWeight: bold;
@activeIconOpacity: 1; @activeIconOpacity: 1;
@activeItemBoxShadow: none; @activeItemBoxShadow: none;
@ -236,8 +232,6 @@
@secondaryHeaderBackground: none transparent; @secondaryHeaderBackground: none transparent;
@secondaryHeaderBorder: 0.1em solid rgba(0, 0, 0, 0.1); @secondaryHeaderBorder: 0.1em solid rgba(0, 0, 0, 0.1);
@secondaryInvertedActiveBackground: @transparentWhite;
@secondaryVerticalItemMargin: 0em 0em 0.3em; @secondaryVerticalItemMargin: 0em 0em 0.3em;
@secondaryVerticalItemBorderRadius: @defaultBorderRadius; @secondaryVerticalItemBorderRadius: @defaultBorderRadius;
@ -258,9 +252,17 @@
@secondaryPointingActiveHoverTextColor: @secondaryPointingActiveTextColor; @secondaryPointingActiveHoverTextColor: @secondaryPointingActiveTextColor;
@secondaryPointingHeaderColor: @darkTextColor; @secondaryPointingHeaderColor: @darkTextColor;
@secondaryVerticalPointingItemMargin: 0em -@secondaryPointingBorderWidth 0em 0em; @secondaryVerticalPointingItemMargin: 0em -@secondaryPointingBorderWidth 0em 0em;
/* Inverted Secondary */
@secondaryInvertedColor: @invertedLightTextColor;
@secondaryInvertedHoverBackground: @transparentWhite;
@secondaryInvertedHoverColor: @invertedSelectedTextColor;
@secondaryInvertedActiveBackground: @strongTransparentWhite;
@secondaryInvertedActiveColor: @invertedSelectedTextColor;
/* Inverted Pointing */
@secondaryPointingInvertedBorderColor: @whiteBorderColor; @secondaryPointingInvertedBorderColor: @whiteBorderColor;
@secondaryPointingInvertedItemTextColor: @invertedTextColor; @secondaryPointingInvertedItemTextColor: @invertedTextColor;
@secondaryPointingInvertedItemHeaderColor: @white; @secondaryPointingInvertedItemHeaderColor: @white;
@ -371,22 +373,25 @@
@invertedSubMenuHoverColor: @white; @invertedSubMenuHoverColor: @white;
/* Pressed */ /* Pressed */
@invertedMenuPressedBackground: rgba(255, 255, 255, 0.15);
@invertedMenuPressedBackground: rgba(255, 255, 255, 0.05);
@invertedMenuPressedColor: @white; @invertedMenuPressedColor: @white;
/* Inverted Active */ /* Inverted Active */
@invertedActiveBackground: rgba(255, 255, 255, 0.2);
@invertedActiveBackground: rgba(255, 255, 255, 0.15);
@invertedActiveColor: @white; @invertedActiveColor: @white;
@invertedArrowActiveColor: #3C3C3C;
/* Inverted Active Hover */
@invertedActiveHoverBackground: rgba(255, 255, 255, 0.15);
@invertedActiveHoverColor: @white;
@invertedArrowActiveHoverColor: #3C3C3C;
@invertedSubMenuActiveBackground: transparent; @invertedSubMenuActiveBackground: transparent;
@invertedSubMenuActiveColor: @white; @invertedSubMenuActiveColor: @white;
/* Inverted Secondary */
@secondaryInvertedColor: @invertedLightTextColor;
@secondaryInvertedHoverColor: @invertedSelectedTextColor;
/* Inverted Menu Divider */ /* Inverted Menu Divider */
@invertedDividerBackground: @invertedBorderColor;
@invertedVerticalDividerBackground: @invertedBorderColor;
@invertedDividerBackground: rgba(255, 255, 255, 0.05);
@invertedVerticalDividerBackground: @invertedDividerBackground;
/* Fixed */ /* Fixed */
@fixedGridMargin: 2.75rem; @fixedGridMargin: 2.75rem;

Loading…
Cancel
Save