Trevor Parscal has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/129563

Change subject: Make new styles target .mw-content instead of #bodyContent
......................................................................

Make new styles target .mw-content instead of #bodyContent

Font size, line height and positioning styles related to content should be 
something we can apply anywhere rendered Wikitext is displayed, not just the 
#bodyContent div.

The use of classes for content styling has been recommended and generally 
agreed upon in IRC discussions, specifically in the context of the RFC about 
scoping site CSS:
https://www.mediawiki.org/wiki/Requests_for_comment/Scoping_site_CSS

This change takes the first step toward introducing a resizable class 
throughout the UI to apply rendered content-specific styles where needed.

This also makes it possible to resolve a bug in which VisualEditor does not 
receive the correct styles because it is created outside the #bodyContent div.

Change-Id: I66c56c577bad064261c3e4a62a1c1b2566d53972
---
M skins/Vector.php
M skins/vector/components/common.less
2 files changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/63/129563/1

diff --git a/skins/Vector.php b/skins/Vector.php
index a8d3477..5fb97c3 100644
--- a/skins/Vector.php
+++ b/skins/Vector.php
@@ -177,7 +177,7 @@
                        $this->text( 'pageLanguage' );
                        ?>"><span dir="auto"><?php $this->html( 'title' ) 
?></span></h1>
                        <?php $this->html( 'prebodyhtml' ) ?>
-                       <div id="bodyContent">
+                       <div id="bodyContent" class="mw-content">
                                <?php
                                if ( $this->data['isarticle'] ) {
                                        ?>
diff --git a/skins/vector/components/common.less 
b/skins/vector/components/common.less
index 76d1873..725ddfe 100644
--- a/skins/vector/components/common.less
+++ b/skins/vector/components/common.less
@@ -127,7 +127,7 @@
        vertical-align: text-bottom;
 }
 
-#bodyContent {
+.mw-content {
        position: relative;
        line-height: @content-line-height;
        font-size: @content-font-size;

-- 
To view, visit https://gerrit.wikimedia.org/r/129563
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I66c56c577bad064261c3e4a62a1c1b2566d53972
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Trevor Parscal <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to