mediawiki-skins-Vector/resources/common/mixins.less

56 lines
1.6 KiB
Plaintext
Raw Normal View History

/**
* Less mixins shared between both legacy and Vector 2022.
*/
@import '../common/variables.less';
.mixin-vector-menu-heading() {
align-self: center;
color: @color-base--subtle;
font-weight: normal;
cursor: default;
// NOTE: Setting these values does not produce a visible border.
// That's handled elsewhere with either border-top-style or border-bottom-style.
border-color: @border-color-portal-heading;
border-width: @border-width-base;
}
// Defines the arrow beside dropdown headings.
.mixin-vector-legacy-menu-heading-arrow {
content: '';
background: url( ../common/images/arrow-down.svg ) 100% 50% no-repeat;
width: unit( 16 / @font-size-tabs / @font-size-browser, em );
height: unit( 16 / @font-size-tabs / @font-size-browser, em );
}
.mixin-vector-menu-heading-arrow() {
content: '';
background: url( ../common/images/arrow-down.svg ) 100% 50% no-repeat;
width: unit( 16 / @font-size-tabs / @font-size-browser, em );
height: unit( 16 / @font-size-tabs / @font-size-browser, em );
// https://phabricator.wikimedia.org/T319070#8284272
margin-left: -1px;
}
// Remove this mixin after VectorPageTools is enabled everywhere
.mixin-vector-dropdown-menu-item-deprecated() {
min-height: @height-dropdown-menu-item;
padding: @padding-dropdown-menu-item;
}
.mixin-vector-dropdown-menu-item() {
display: flex;
align-items: center;
padding: @padding-vertical-dropdown-menu-item @padding-horizontal-dropdown-menu-item;
font-size: @font-size-dropdown;
&:visited {
color: @color-link;
}
&.selected a,
&.selected a:visited {
color: @color-link-selected;
}
}