From 02d71fa2cfc188e8e5c83e10290a71ef312782ad Mon Sep 17 00:00:00 2001 From: Baha Date: Tue, 2 Aug 2016 14:45:22 -0400 Subject: [PATCH] Wrap revision info and nav in a div for easy formatting in MobileFrontend Revision info and nav used to be combined with breadcrumbs which made styling the revision info and nav complicated. The patch wraps these two divs into an outer div so that MF can style them together easily. Also make sure rev info and nav appear on different lines as the `br` tag between them has been removed because of wrapping. Bug: T139930 Change-Id: Ic7ecf3be7eac6500c20cfc3b3b1fa49d4b4e0d19 --- includes/page/Article.php | 11 ++++++----- resources/src/mediawiki.legacy/shared.css | 1 - 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/includes/page/Article.php b/includes/page/Article.php index 2a6f88c577..6396aaabcf 100644 --- a/includes/page/Article.php +++ b/includes/page/Article.php @@ -1438,14 +1438,13 @@ class Article implements Page { : 'revision-info'; $outputPage = $context->getOutput(); - $outputPage->addSubtitle( "
" . + $revisionInfo = "
" . $context->msg( $infomsg, $td ) ->rawParams( $userlinks ) ->params( $revision->getId(), $tddate, $tdtime, $revision->getUserText() ) ->rawParams( Linker::revComment( $revision, true, true ) ) ->parse() . - "
" - ); + "
"; $lnk = $current ? $context->msg( 'currentrevisionlink' )->escaped() @@ -1517,10 +1516,12 @@ class Article implements Page { $cdel .= ' '; } - $outputPage->addSubtitle( "
" . $cdel . + // the outer div is need for styling the revision info and nav in MobileFrontend + $outputPage->addSubtitle( "
" . $revisionInfo . + "
" . $cdel . $context->msg( 'revision-nav' )->rawParams( $prevdiff, $prevlink, $lnk, $curdiff, $nextlink, $nextdiff - )->escaped() . "
" ); + )->escaped() . "
" ); } /** diff --git a/resources/src/mediawiki.legacy/shared.css b/resources/src/mediawiki.legacy/shared.css index fc163776ca..8fcc667303 100644 --- a/resources/src/mediawiki.legacy/shared.css +++ b/resources/src/mediawiki.legacy/shared.css @@ -704,7 +704,6 @@ ol:lang(or) li { #mw-revision-info-current, #mw-revision-nav { direction: ltr; - display: inline; } /* Images */ -- 2.20.1