Remove mw-body-content from HTML that is not the article body

The `mw-body-content` class is currently decorating various things,
however should be limited to the body of the article. This allows
us to identify the wrapping element without resorting to a selector
that makes use of an identifier and to separate styling concerns of
UI (indicators and site notice) from article content.

Bug: T279388
Change-Id: I4c1b15d90bacbc9b13782a1d8f52e838ce8ecd83
This commit is contained in:
Jdlrobson 2021-04-26 16:25:30 -07:00
parent 63f9dd81e3
commit efaf3aadf3
4 changed files with 6 additions and 8 deletions

View File

@ -1,5 +1,5 @@
{{! @typedef Indicator[]}}
<div class="mw-indicators mw-body-content">
<div class="mw-indicators">
{{#array-indicators}}
<div id="{{id}}" class="{{class}}">{{{html}}}</div>
{{/array-indicators}}

View File

@ -29,10 +29,10 @@
<div id="mw-head-base" class="noprint"></div>
<div id="content" class="mw-body" role="main">
<a id="top"></a>
<div id="siteNotice" class="mw-body-content">{{{html-site-notice}}}</div>
<div id="siteNotice">{{{html-site-notice}}}</div>
{{>Indicators}}
<h1 id="firstHeading" class="firstHeading" {{{html-user-language-attributes}}}>{{{html-title}}}</h1>
<div id="bodyContent" class="mw-body-content">
<div id="bodyContent">
{{#is-article}}<div id="siteSub" class="noprint">{{msg-tagline}}</div>{{/is-article}}
<div id="contentSub"{{{html-user-language-attributes}}}>{{{html-subtitle}}}</div>
<div id="contentSub2">{{{html-undelete-link}}}</div>

View File

@ -48,7 +48,7 @@
{{! `role` is unnecessary but kept to support selectors in any gadgets or user styles. }}
<main id="content" class="mw-body" role="main">
<a id="top"></a>
<div id="siteNotice" class="mw-body-content">{{{html-site-notice}}}</div>
<div id="siteNotice">{{{html-site-notice}}}</div>
{{^is-language-in-header}}
{{>Indicators}}
@ -70,7 +70,7 @@
</header>
{{/is-language-in-header}}
<div id="bodyContent" class="mw-body-content">
<div id="bodyContent">
{{^is-language-in-header}}
{{#is-article}}<div id="siteSub" class="noprint">{{msg-tagline}}</div>{{/is-article}}
{{/is-language-in-header}}

View File

@ -100,7 +100,6 @@
"skins.vector.styles.legacy": {
"class": "ResourceLoaderSkinModule",
"features": {
"content-parser-output": true,
"normalize": true,
"elements": true,
"content": true,
@ -124,8 +123,7 @@
"elements": true,
"content": true,
"interface": true,
"legacy": true,
"content-parser-output": true
"legacy": true
},
"targets": [
"desktop",