2021-02-02 10:04:37 +00:00
|
|
|
/**
|
|
|
|
* Vector modern layout styles for screen
|
|
|
|
*
|
|
|
|
* Layout rules divide the page into sections and how VectorComponents should be arranged in the skin.
|
|
|
|
* The rules here should only define the layout, not color or typography.
|
|
|
|
*/
|
|
|
|
|
|
|
|
@import '../../common/variables.less';
|
|
|
|
@import 'mediawiki.mixins.less';
|
|
|
|
|
2022-08-17 18:57:38 +00:00
|
|
|
@selector-sidebar-no-toc-sidebar-closed: ~'@{selector-main-menu-closed} ~ .vector-sidebar-container-no-toc';
|
2022-05-12 16:05:26 +00:00
|
|
|
|
2022-05-30 03:46:57 +00:00
|
|
|
// Content container
|
2021-02-02 10:04:37 +00:00
|
|
|
|
|
|
|
// Note this uses variables defined in mediawiki.skin.variables so that VisualEditor can read them
|
|
|
|
// see T259331.
|
2022-09-15 18:53:18 +00:00
|
|
|
@padding-content: @padding-top-content 0 1.5em;
|
2021-02-02 10:04:37 +00:00
|
|
|
|
|
|
|
// Breakpoints
|
|
|
|
|
|
|
|
// Defines the minimum viewport width, at which point the layout will not get any
|
|
|
|
// smaller and will start horizontal scrolling instead.
|
2022-09-15 18:53:18 +00:00
|
|
|
@min-width-supported: unit( 500px / @font-size-browser, em );
|
2020-08-10 21:40:06 +00:00
|
|
|
|
|
|
|
body {
|
2020-10-30 16:57:38 +00:00
|
|
|
background-color: @background-color-secondary--modern;
|
2020-08-10 21:40:06 +00:00
|
|
|
color: @color-base;
|
|
|
|
// Vertical scrollbar always visible.
|
|
|
|
overflow-y: scroll;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mw-body,
|
|
|
|
.parsoid-body {
|
|
|
|
direction: ltr;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mw-body {
|
2022-09-15 18:53:18 +00:00
|
|
|
// T315261 Remove horizontal padding, rely on .mw-page-container padding instead
|
2020-10-30 16:57:38 +00:00
|
|
|
padding: @padding-content;
|
2020-08-10 21:40:06 +00:00
|
|
|
|
|
|
|
.firstHeading {
|
|
|
|
/* Change the default from mediawiki.skinning CSS to let indicators float into heading area */
|
|
|
|
overflow: visible;
|
2022-06-06 21:39:57 +00:00
|
|
|
margin-bottom: 0;
|
2020-08-10 21:40:06 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-09-08 23:20:58 +00:00
|
|
|
.mw-header {
|
2020-11-19 17:12:53 +00:00
|
|
|
// allow z-index to apply so search results overlay article
|
|
|
|
position: relative;
|
2020-08-10 21:40:06 +00:00
|
|
|
z-index: @z-index-header;
|
|
|
|
}
|
|
|
|
|
2022-07-25 20:13:58 +00:00
|
|
|
.mw-body-content {
|
|
|
|
margin-top: 16px;
|
|
|
|
}
|
|
|
|
|
2020-08-10 21:40:06 +00:00
|
|
|
/* Main column */
|
|
|
|
.mw-body,
|
|
|
|
#mw-data-after-content,
|
|
|
|
.mw-footer {
|
2020-10-30 16:57:38 +00:00
|
|
|
margin-left: 0;
|
2020-08-10 21:40:06 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/* Content */
|
|
|
|
.mw-indicators {
|
|
|
|
z-index: @z-index-indicators;
|
|
|
|
}
|
|
|
|
|
2022-10-17 20:09:53 +00:00
|
|
|
.vector-page-titlebar,
|
|
|
|
.vector-body-before-content {
|
2021-01-22 18:24:34 +00:00
|
|
|
.mixin-clearfix();
|
|
|
|
}
|
|
|
|
|
2022-03-14 18:49:23 +00:00
|
|
|
.mw-body .mw-portlet-lang {
|
2021-05-03 13:48:46 +00:00
|
|
|
float: right;
|
|
|
|
}
|
2021-09-28 16:27:10 +00:00
|
|
|
|
2021-05-21 01:02:07 +00:00
|
|
|
.vector-body {
|
2020-08-10 21:40:06 +00:00
|
|
|
position: relative;
|
|
|
|
z-index: @z-index-base;
|
2022-09-23 16:57:02 +00:00
|
|
|
}
|
2022-08-03 20:52:07 +00:00
|
|
|
|
2022-09-23 16:57:02 +00:00
|
|
|
#siteSub {
|
|
|
|
// By default its hidden as it was hidden in Vector legacy but site styles can reveal.
|
|
|
|
display: none;
|
|
|
|
margin-top: 8px; // T311564
|
|
|
|
}
|
2022-08-03 20:52:07 +00:00
|
|
|
|
2022-09-23 16:57:02 +00:00
|
|
|
// Styles only applied to non-empty #contentSub to avoid extra margins when both #contentSub and #contentSub2
|
|
|
|
// are rendered.
|
|
|
|
#contentSub:not( :empty ),
|
|
|
|
#contentSub2 {
|
|
|
|
font-size: 84%;
|
|
|
|
line-height: 1.2em;
|
|
|
|
color: @color-base--subtle;
|
|
|
|
width: auto;
|
|
|
|
// Visually separate #contentSub and #contentSub2 (T315639)
|
|
|
|
margin: 8px 0 0;
|
2020-08-10 21:40:06 +00:00
|
|
|
}
|
|
|
|
|
2020-10-30 16:57:38 +00:00
|
|
|
.parsoid-body {
|
|
|
|
padding: @padding-content;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Container logic.
|
|
|
|
.mw-page-container {
|
2022-03-16 07:59:07 +00:00
|
|
|
// Setting position and z-index is important as it allows overlays appended to the body tag
|
|
|
|
// to position themselves over the Vector interface. This forms another stacking context for
|
|
|
|
// elements placed inside this element
|
|
|
|
position: relative;
|
|
|
|
z-index: 0;
|
2020-10-30 16:57:38 +00:00
|
|
|
max-width: @max-width-page-container;
|
2022-09-15 18:53:18 +00:00
|
|
|
// Set a min-width to make explicit we do not support anything below this threshold.
|
|
|
|
// For devices too small, they should be more useable with horizontal scrolling.
|
|
|
|
// e.g. Portrait on an iPad
|
|
|
|
min-width: @min-width-supported;
|
2020-10-30 16:57:38 +00:00
|
|
|
// Fill the viewport even if the content height is small. This also helps
|
|
|
|
// mitigate a long sidebar overflowing the page container (T257518).
|
|
|
|
min-height: 100%;
|
|
|
|
margin-left: auto;
|
|
|
|
margin-right: auto;
|
2021-01-05 18:01:45 +00:00
|
|
|
// Use non-zero padding to disable margin collapse.
|
|
|
|
// Be careful not to use overflow-y: scroll here (see T270146 and T271868)
|
2022-09-01 16:23:55 +00:00
|
|
|
padding: 0.05px @padding-horizontal-page-container;
|
2020-10-30 16:57:38 +00:00
|
|
|
background-color: @background-color-page-container;
|
2022-09-15 18:53:18 +00:00
|
|
|
box-sizing: border-box;
|
2022-04-28 18:21:52 +00:00
|
|
|
|
2022-10-21 17:39:16 +00:00
|
|
|
// FIXME: Remove `.skin-vector-disable-max-width` when caching no longer an issue.
|
|
|
|
.vector-feature-limited-width-disabled &,
|
|
|
|
.skin-vector-disable-max-width & {
|
|
|
|
max-width: none;
|
|
|
|
}
|
|
|
|
|
2022-06-23 21:33:47 +00:00
|
|
|
@media ( min-width: @min-width-desktop ) {
|
2022-09-01 16:23:55 +00:00
|
|
|
padding-left: @padding-horizontal-page-container-desktop;
|
|
|
|
padding-right: @padding-horizontal-page-container-desktop;
|
2022-04-28 18:21:52 +00:00
|
|
|
}
|
|
|
|
|
2022-06-23 21:33:47 +00:00
|
|
|
@media ( min-width: @min-width-desktop-wide ) {
|
2022-09-01 16:23:55 +00:00
|
|
|
padding-left: @padding-horizontal-page-container-desktop-wide;
|
|
|
|
padding-right: @padding-horizontal-page-container-desktop-wide;
|
2022-04-28 18:21:52 +00:00
|
|
|
}
|
2020-10-30 16:57:38 +00:00
|
|
|
}
|
|
|
|
|
2021-01-29 01:53:27 +00:00
|
|
|
.skin--responsive .mw-page-container {
|
|
|
|
min-width: auto;
|
|
|
|
}
|
|
|
|
|
2022-06-02 22:09:28 +00:00
|
|
|
@import 'grid.less';
|