mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue
synced 2024-12-21 01:52:49 +00:00
dd154b4ea7
The values have slightly changed: - Tablet breakpoint is decreased by 80px, pushing lesser devices into a mobile only experience but should make barely a difference to vast majority of our users. - Biggest difference is in `min-width-breakpoint-desktop`, which is increased by 120px in comparison to `@width-breakpoint-desktop: 1000px` Also removing one out-dated feature phone clause. TECHNICAL CHANGES: * The previous breakpoint was tied to the maximum content width. The previous maximum content width is preserved, and several media queries are adjusted to make use of it. * The header (logo) is not optimized for 640px-720px. For now a temporary fix is but in place which will be investigated as part of T366859 VISUAL CHANGES: * 6 visual changes which improve alignment in language and visual editor overlay and diffs (where wikidiff2 is not installed) Bug: T349793 Depends-On: I3afba8c51f60de9271054499bfa3ffbcc1a9d779 Change-Id: I9552d8ad7509aae90e15edda26e786465773d3ac
157 lines
3.8 KiB
Plaintext
157 lines
3.8 KiB
Plaintext
@import '../../../../minerva.less/minerva.variables.less';
|
|
|
|
/**
|
|
* Ambox classes are nested in a top-level class
|
|
* for the page issues A/B test.
|
|
* This class is appended to the DOM via JS
|
|
**/
|
|
|
|
@amboxPadding: 8px;
|
|
@amboxIconPadding: @amboxPadding * 4;
|
|
|
|
.ambox,
|
|
/* Be more specific than .content table styles in Minerva */
|
|
table.ambox {
|
|
display: none;
|
|
margin: 0;
|
|
}
|
|
|
|
// Will show FOUC on mobile
|
|
.issues-group-B {
|
|
.ambox {
|
|
display: block;
|
|
}
|
|
}
|
|
|
|
.client-js .ambox {
|
|
cursor: pointer;
|
|
width: auto;
|
|
// !important needed to override core ambox styles
|
|
background: var( --background-color-interactive-subtle ) !important;
|
|
color: var( --color-subtle );
|
|
margin-bottom: 1px;
|
|
|
|
tbody {
|
|
display: table;
|
|
width: 100%;
|
|
}
|
|
|
|
// Assuming that most ambox templates wrap content in this element.
|
|
// See https://en.wikipedia.org/w/index.php?title=Module:Message_box&action=raw (search for 'mbox-text-span').
|
|
// https://phabricator.wikimedia.org/T206887 suggests .mbox-text-div is also needed.
|
|
.mbox-text-div,
|
|
.mbox-text-span {
|
|
display: block;
|
|
max-height: @line-height-content * 2em;
|
|
// All will have this height (approx 2 lines) even if a single line e.g. {{dictdef}} when on mobile.
|
|
// Overriden later in tablet styles.
|
|
height: @line-height-content * 2em;
|
|
overflow: hidden;
|
|
}
|
|
|
|
// Wrestle with inline styles that editors may place on elements inside the ambox
|
|
div {
|
|
// e.g. on mw-collapsible inside Multiple issues template
|
|
margin: 0 !important;
|
|
// e.g. on Template:Expand Russian
|
|
padding: 0 !important;
|
|
}
|
|
|
|
td,
|
|
div.mbox-text {
|
|
position: relative;
|
|
// Override !important above if this is a div
|
|
padding: @amboxPadding @amboxPadding @amboxPadding @amboxIconPadding !important;
|
|
|
|
> div,
|
|
> span {
|
|
font-size: @font-size-minerva-smallest;
|
|
}
|
|
}
|
|
|
|
// All text should be treated the same
|
|
b {
|
|
font-weight: inherit;
|
|
}
|
|
|
|
// Hide links in new treatment
|
|
a {
|
|
color: inherit !important;
|
|
-webkit-tap-highlight-color: rgba( 0, 0, 0, 0 ) !important;
|
|
|
|
&:hover,
|
|
&:focus {
|
|
text-decoration: none;
|
|
outline: inherit;
|
|
}
|
|
}
|
|
|
|
small,
|
|
.hide-when-compact,
|
|
/* Template:Expand Russian */
|
|
.mw-collapsible-content,
|
|
/* Remove empty leftmost column when present (.mbox-empty-cell)
|
|
* and .verbose and any hr tags that might be present in the ambox
|
|
* See https://en.wikipedia.org/w/index.php?
|
|
* title=Special:WhatLinksHere/Template:Proposed_deletion_notify
|
|
* (https://phabricator.wikimedia.org/T197265) */
|
|
.mbox-empty-cell,
|
|
hr,
|
|
.verbose,
|
|
/* Nested amboxes (multiple issues) */
|
|
table,
|
|
.mbox-image {
|
|
display: none;
|
|
}
|
|
|
|
.minerva-ambox-icon {
|
|
position: absolute;
|
|
left: @amboxPadding;
|
|
top: 11px;
|
|
}
|
|
|
|
.ambox-learn-more {
|
|
color: @color-link;
|
|
position: absolute;
|
|
right: @amboxPadding;
|
|
bottom: @amboxPadding;
|
|
z-index: @z-index-base;
|
|
line-height: @line-height-content; // sets height for fade & aligns "learn more" to ambox text.
|
|
|
|
/* creates a fade under the "learn more" button to avoid overlapping text. */
|
|
&::before {
|
|
content: '';
|
|
position: absolute;
|
|
z-index: @z-index-occluded;
|
|
bottom: 0;
|
|
right: 0;
|
|
width: 100%; // width & height defined by length of "learn more".
|
|
height: 100%;
|
|
box-sizing: content-box; // explicitly setting box-sizing so padding extends beyond 100%.
|
|
padding-left: 4em;
|
|
background: linear-gradient( to right, transparent 0, var( --background-color-interactive-subtle ) 3em );
|
|
}
|
|
}
|
|
|
|
@media screen and ( min-width: @min-width-breakpoint-tablet ) {
|
|
.mbox-text-div,
|
|
.mbox-text-span {
|
|
height: auto;
|
|
margin-bottom: @amboxPadding * 3 !important; // important offsets `.ambox div { margin:0!important}` which offsets inline styles.
|
|
}
|
|
|
|
.ambox-learn-more {
|
|
left: @amboxIconPadding;
|
|
right: 0;
|
|
background: none;
|
|
|
|
// Move blur to far right last line
|
|
// https://phabricator.wikimedia.org/T197931#4475197
|
|
&::before {
|
|
top: unit( -@line-height-content, em );
|
|
width: 10px;
|
|
}
|
|
}
|
|
}
|
|
}
|