2022-06-02 22:09:28 +00:00
|
|
|
//
|
|
|
|
// Grid layout
|
|
|
|
//
|
2022-06-30 22:37:08 +00:00
|
|
|
|
2023-01-06 18:07:35 +00:00
|
|
|
/* Use of minmax is important to restrict the maximum grid column width more information: T314756 */
|
2023-01-09 18:20:21 +00:00
|
|
|
@grid-template-column-desktop: ~'@{width-column-start-desktop} minmax(0, 1fr)';
|
|
|
|
@grid-template-column-desktop-wide: ~'@{width-column-start-desktop-wide} minmax(0, 1fr)';
|
2023-01-06 18:07:35 +00:00
|
|
|
|
2022-08-04 20:05:36 +00:00
|
|
|
@media ( min-width: @min-width-desktop ) {
|
|
|
|
.mw-page-container-inner {
|
|
|
|
display: grid;
|
2023-01-09 18:20:21 +00:00
|
|
|
column-gap: @grid-column-gap;
|
2023-03-28 18:38:37 +00:00
|
|
|
grid-template: ~'min-content min-content 1fr min-content / @{grid-template-column-desktop}';
|
|
|
|
grid-template-areas: 'siteNotice siteNotice'
|
2022-10-20 21:52:21 +00:00
|
|
|
'mainMenu pageContent'
|
|
|
|
'toc pageContent'
|
2022-09-01 16:23:55 +00:00
|
|
|
'footer footer';
|
2022-08-04 20:05:36 +00:00
|
|
|
}
|
|
|
|
|
2022-08-22 20:23:14 +00:00
|
|
|
.vector-sitenotice-container {
|
2022-10-20 21:52:21 +00:00
|
|
|
grid-area: siteNotice;
|
2022-06-24 20:17:36 +00:00
|
|
|
}
|
|
|
|
|
2022-08-04 20:05:36 +00:00
|
|
|
.mw-table-of-contents-container {
|
|
|
|
grid-area: toc;
|
2023-02-21 02:25:03 +00:00
|
|
|
overflow-anchor: none; // T330108
|
2022-06-02 22:09:28 +00:00
|
|
|
}
|
|
|
|
|
2022-10-17 20:09:53 +00:00
|
|
|
.vector-main-menu-container {
|
2022-10-20 21:52:21 +00:00
|
|
|
grid-area: mainMenu;
|
2023-02-21 02:25:03 +00:00
|
|
|
overflow-anchor: none; // T330108
|
2022-06-02 22:09:28 +00:00
|
|
|
}
|
|
|
|
|
2022-08-04 20:05:36 +00:00
|
|
|
.mw-content-container {
|
2022-10-20 21:52:21 +00:00
|
|
|
grid-area: pageContent;
|
2022-08-04 20:05:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mw-footer-container {
|
|
|
|
grid-area: footer;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@media ( min-width: @min-width-desktop-wide ) {
|
|
|
|
.mw-page-container-inner {
|
2023-01-06 18:07:35 +00:00
|
|
|
grid-template-columns: @grid-template-column-desktop-wide;
|
|
|
|
}
|
|
|
|
|
2023-03-28 15:26:22 +00:00
|
|
|
.mw-header {
|
2023-01-06 18:07:35 +00:00
|
|
|
display: grid;
|
2023-01-09 18:20:21 +00:00
|
|
|
column-gap: @grid-column-gap;
|
2023-01-06 18:07:35 +00:00
|
|
|
grid-template: ~'auto / @{grid-template-column-desktop-wide}';
|
|
|
|
grid-template-areas: 'headerStart headerEnd';
|
|
|
|
|
|
|
|
.vector-header-start {
|
|
|
|
grid-area: headerStart;
|
|
|
|
}
|
|
|
|
|
|
|
|
.vector-header-end {
|
|
|
|
grid-area: headerEnd;
|
|
|
|
}
|
2022-08-04 20:05:36 +00:00
|
|
|
}
|
|
|
|
}
|
2023-07-11 23:13:57 +00:00
|
|
|
// FIXME: Remove -disabled when cache has cleared.
|
|
|
|
&.vector-feature-limited-width-clientpref-0 .mw-content-container,
|
|
|
|
&.vector-feature-limited-width-clientpref-0 .mw-table-of-contents-container,
|
2023-04-24 22:48:12 +00:00
|
|
|
&.vector-feature-limited-width-disabled .mw-content-container,
|
|
|
|
&.vector-feature-limited-width-content-disabled .mw-content-container,
|
|
|
|
&.vector-feature-limited-width-disabled .mw-table-of-contents-container,
|
|
|
|
&.vector-feature-limited-width-content-disabled .mw-table-of-contents-container {
|
|
|
|
// Allow the max-width of content on history/special pages to be wider than
|
|
|
|
// the max-width of content on article pages.
|
|
|
|
// Note, we don't disable the max-width on .vector-page-toolbar-container intentionally
|
|
|
|
// to support easier navigation between tabs.
|
|
|
|
// See T293441 for further information on that.
|
|
|
|
// Both rules are !important as they are final. Max-width on a page should be restored by removing the `skin-vector-disable-max-width`,
|
|
|
|
// preferably by modification to the feature flag VectorMaxWidthOptions. Code should never attempt to override this rule.
|
|
|
|
/* stylelint-disable-next-line declaration-no-important */
|
|
|
|
max-width: none !important;
|
|
|
|
/* stylelint-disable-next-line declaration-no-important */
|
|
|
|
width: 100% !important;
|
2022-10-20 21:52:21 +00:00
|
|
|
}
|
|
|
|
|
2022-12-06 23:40:03 +00:00
|
|
|
// Horizontally center content when column start is empty (i.e. no pinned ToC or pinned main menu)
|
2023-04-24 22:48:12 +00:00
|
|
|
&.vector-feature-main-menu-pinned-disabled .vector-sidebar-container-no-toc ~ .mw-content-container,
|
|
|
|
&.vector-feature-main-menu-pinned-disabled.vector-feature-toc-pinned-disabled .mw-content-container {
|
2023-03-28 15:26:22 +00:00
|
|
|
grid-column: mainMenu / pageContent;
|
|
|
|
margin-left: auto;
|
|
|
|
margin-right: auto;
|
2022-10-20 21:52:21 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
@media ( min-width: @min-width-desktop ) {
|
2023-03-28 15:26:22 +00:00
|
|
|
.mw-body {
|
2022-10-20 21:52:21 +00:00
|
|
|
display: grid;
|
2023-01-25 00:36:24 +00:00
|
|
|
grid-template: ~'min-content min-content min-content 1fr / minmax(0, @{max-width-content-container}) min-content';
|
2023-01-23 22:26:53 +00:00
|
|
|
/**
|
|
|
|
* NOTE: T327715 - 'titlebar-cx' grid area is a temporary workaround to accommodate
|
|
|
|
* the Content Translation extension and should not be used beyond that.
|
|
|
|
* FIXME: This can be removed when T322740 is resolved.
|
|
|
|
*/
|
|
|
|
grid-template-areas: 'titlebar-cx .'
|
2023-02-09 22:50:25 +00:00
|
|
|
'titlebar columnEnd'
|
2022-10-20 21:52:21 +00:00
|
|
|
'toolbar columnEnd'
|
|
|
|
'content columnEnd';
|
|
|
|
|
|
|
|
.vector-page-titlebar {
|
|
|
|
grid-area: titlebar;
|
|
|
|
}
|
|
|
|
|
|
|
|
.vector-page-toolbar {
|
|
|
|
grid-area: toolbar;
|
|
|
|
}
|
|
|
|
|
|
|
|
#bodyContent {
|
|
|
|
grid-area: content;
|
|
|
|
}
|
|
|
|
|
|
|
|
.vector-column-end {
|
|
|
|
grid-area: columnEnd;
|
2023-03-28 15:26:22 +00:00
|
|
|
overflow-anchor: none;
|
2022-10-20 21:52:21 +00:00
|
|
|
}
|
2022-08-15 14:42:34 +00:00
|
|
|
}
|
2023-03-28 15:26:22 +00:00
|
|
|
|
2023-04-24 22:48:12 +00:00
|
|
|
&.vector-feature-page-tools-pinned-enabled .mw-body {
|
2023-03-28 15:26:22 +00:00
|
|
|
column-gap: @grid-column-gap;
|
|
|
|
}
|
|
|
|
|
2023-07-11 23:13:57 +00:00
|
|
|
// FIXME: Remove -disabled when cache has cleared.
|
|
|
|
&.vector-feature-limited-width-clientpref-0 .mw-body,
|
2023-04-24 22:48:12 +00:00
|
|
|
&.vector-feature-limited-width-disabled .mw-body,
|
|
|
|
&.vector-feature-limited-width-content-disabled .mw-body {
|
2023-03-28 15:26:22 +00:00
|
|
|
grid-template-columns: ~'minmax(0, 1fr) min-content';
|
|
|
|
}
|
2022-08-15 14:42:34 +00:00
|
|
|
}
|