IoannisKydonis has uploaded a new change for review.

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

Change subject: Replace obsolete HTML attributes with CSS.
......................................................................

Replace obsolete HTML attributes with CSS.

Replace align attribute in FlaggedRevs extensions.

Bug: T42215
Change-Id: Id932118ee1c4eb5fc16dd4164902345c5c820f7a
---
M frontend/FlaggablePageView.php
M frontend/FlaggedRevsXML.php
M frontend/specialpages/reports/ValidationStatistics_body.php
3 files changed, 13 insertions(+), 13 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/FlaggedRevs 
refs/changes/54/267154/1

diff --git a/frontend/FlaggablePageView.php b/frontend/FlaggablePageView.php
index 5c5d54e..4c021de 100755
--- a/frontend/FlaggablePageView.php
+++ b/frontend/FlaggablePageView.php
@@ -818,7 +818,7 @@
                $tableClass = 'diff diff-contentalign-' .
                        htmlspecialchars( 
$this->getTitle()->getPageLanguage()->alignStart() );
                if ( $multiNotice != '' ) {
-                       $multiNotice = "<tr><td colspan='4' align='center' 
class='diff-multi'>" .
+                       $multiNotice = "<tr><td colspan='4' style='text-align: 
center;' class='diff-multi'>" .
                                $multiNotice . "</td></tr>";
                }
                return
@@ -828,9 +828,9 @@
                                "<col class='diff-marker' />" .
                                "<col class='diff-content' />" .
                                "<tr>" .
-                                       "<td colspan='2' width='50%' 
align='center' class='diff-otitle'><b>" .
+                                       "<td colspan='2' width='50%' 
style='text-align: center;' class='diff-otitle'><b>" .
                                                $leftStatus . "</b></td>" .
-                                       "<td colspan='2' width='50%' 
align='center' class='diff-ntitle'><b>" .
+                                       "<td colspan='2' width='50%' 
style='text-align: center;' class='diff-ntitle'><b>" .
                                                $rightStatus . "</b></td>" .
                                "</tr>" .
                                $multiNotice .
@@ -1596,7 +1596,7 @@
                                array( 'oldid' => $srev->getRevId(), 'diff' => 
'cur' ) + FlaggedRevs::diffOnlyCGI()
                        );
                        $review = wfMessage( 'parentheses' )->rawParams( 
$review )->escaped();
-                       $review = "<div class='fr-diff-to-stable' 
align='center'>$review</div>";
+                       $review = "<div class='fr-diff-to-stable' 
style='margin: auto;'>$review</div>";
                }
                return $review;
        }
@@ -1611,13 +1611,13 @@
                if ( $oldRev && $newRev ) {
                        list( $msg, $class ) = self::getDiffRevMsgAndClass( 
$oldRev, $srev );
                        $table .= "<table class='fr-diff-ratings'><tr>";
-                       $table .= "<td width='50%' align='center'>";
+                       $table .= "<td width='50%' style='text-align: 
center;'>";
                        // @todo i18n FIXME: Hard coded brackets
                        $table .= "<span class='$class'>[" .
                                wfMessage( $msg )->escaped() . "]</span>";
 
                        list( $msg, $class ) = self::getDiffRevMsgAndClass( 
$newRev, $srev );
-                       $table .= "</td><td width='50%' align='center'>";
+                       $table .= "</td><td width='50%' style='text-align: 
center;'>";
                        // @todo i18n FIXME: Hard coded brackets
                        $table .= "<span class='$class'>[" .
                                wfMessage( $msg )->escaped() . "]</span>";
@@ -1627,7 +1627,7 @@
                } elseif ( $newRev ) {
                        list( $msg, $class ) = self::getDiffRevMsgAndClass( 
$newRev, $srev );
                        $table .= "<table class='fr-diff-ratings'>";
-                       $table .= "<tr><td align='center'><span 
class='$class'>";
+                       $table .= "<tr><td style='text-align: center;'><span 
class='$class'>";
                        // @todo i18n FIXME: Hard coded brackets
                        $table .= '[' . wfMessage( $msg )->escaped() . ']';
                        $table .= "</span></td></tr></table>\n";
diff --git a/frontend/FlaggedRevsXML.php b/frontend/FlaggedRevsXML.php
index 8dcf6c1..cdccb49 100644
--- a/frontend/FlaggedRevsXML.php
+++ b/frontend/FlaggedRevsXML.php
@@ -198,7 +198,7 @@
        public static function addTagRatings( $flags, $prettyBox = false, $css 
= '' ) {
                $tag = '';
                if ( $prettyBox ) {
-                       $tag .= "<table id='mw-fr-revisionratings-box' 
align='center' class='$css' cellpadding='0'>";
+                       $tag .= "<table id='mw-fr-revisionratings-box' 
style='margin: auto;' class='$css' cellpadding='0'>";
                }
                foreach ( FlaggedRevs::getTags() as $quality ) {
                        // Give grep a chance to find the usages:
@@ -213,9 +213,9 @@
                        if ( $prettyBox ) {
                                // Give grep a chance to find the usages:
                                // revreview-accuracy, revreview-depth, 
revreview-style
-                               $tag .= "<tr><td class='fr-text' 
valign='middle'>" .
+                               $tag .= "<tr><td class='fr-text' 
style='vertical-align: middle;'>" .
                                        wfMessage( "revreview-$quality" 
)->escaped() .
-                                       "</td><td class='fr-value$levelmarker' 
valign='middle'>" .
+                                       "</td><td class='fr-value$levelmarker' 
style='vertical-align: middle;'>" .
                                        $encValueText . "</td></tr>\n";
                        } else {
                                // Give grep a chance to find the usages:
diff --git a/frontend/specialpages/reports/ValidationStatistics_body.php 
b/frontend/specialpages/reports/ValidationStatistics_body.php
index 8d74b8b..57018a3 100644
--- a/frontend/specialpages/reports/ValidationStatistics_body.php
+++ b/frontend/specialpages/reports/ValidationStatistics_body.php
@@ -44,8 +44,8 @@
                        }
                        $css = 'wikitable flaggedrevs_stats_table';
                        $reviewChart = "<table class='$css' style='white-space: 
nowrap;'>\n";
-                       $reviewChart .= "<tr align='center'>$headerRows</tr>\n";
-                       $reviewChart .= "<tr align='center'>$dataRows</tr>\n";
+                       $reviewChart .= "<tr style='text-align: 
center;'>$headerRows</tr>\n";
+                       $reviewChart .= "<tr style='text-align: 
center;'>$dataRows</tr>\n";
                        $reviewChart .= "</table>\n";
                } else {
                        $reviewChart = '';
@@ -128,7 +128,7 @@
                        $unreviewed = $lang->formatnum( max( 0, $unreviewed ) 
); // lag between queries
 
                        $out->addHTML(
-                               "<tr align='center'>
+                               "<tr style='text-align: center;'>
                                        <td>" .
                                                htmlspecialchars( $NsText ) .
                                        "</td>

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id932118ee1c4eb5fc16dd4164902345c5c820f7a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/FlaggedRevs
Gerrit-Branch: master
Gerrit-Owner: IoannisKydonis <[email protected]>

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

Reply via email to