From: Florian Date: Thu, 24 Mar 2016 17:17:17 +0000 (+0100) Subject: Add new mw-contributions-current css class to Special:Contributions X-Git-Tag: 1.31.0-rc.0~6444^2 X-Git-Url: http://git.cyclocoop.org/data/Luca_Pacioli_%28Gemaelde%29.jpeg?a=commitdiff_plain;h=a07799dae1a2f7c6368960bb2ab04f6b33c896c5;p=lhc%2Fweb%2Fwiklou.git Add new mw-contributions-current css class to Special:Contributions If the current revision of a page, where a user contributed to, is the revision of this user ("current"), add the new css class mw-contributions-current to the li-element to allow styling the whole line differently. Bug: T130824 Change-Id: I556b374585523a7c51278c2dc83bb03fd3b0ee33 --- diff --git a/includes/specials/pagers/ContribsPager.php b/includes/specials/pagers/ContribsPager.php index f4f27487d4..fe0b4fea4b 100644 --- a/includes/specials/pagers/ContribsPager.php +++ b/includes/specials/pagers/ContribsPager.php @@ -371,8 +371,9 @@ class ContribsPager extends ReverseChronologicalPager { # Mark current revisions $topmarktext = ''; $user = $this->getUser(); - if ( $row->rev_id == $row->page_latest ) { + if ( $row->rev_id === $row->page_latest ) { $topmarktext .= '' . $this->messages['uctop'] . ''; + $classes[] = 'mw-contributions-current'; # Add rollback link if ( !$row->page_is_new && $page->quickUserCan( 'rollback', $user ) && $page->quickUserCan( 'edit', $user )