jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/379961 )
Change subject: Wrap links in client watchlists, so that CSS works ...................................................................... Wrap links in client watchlists, so that CSS works Per what hoo wrote in T48329#2272092. Bug: T48329 Bug: T50684 Change-Id: I0f358d8a45235cc456eeefb1e63c8b18505029a7 --- M client/includes/RecentChanges/ChangeLineFormatter.php M client/tests/phpunit/includes/RecentChanges/ChangeLineFormatterTest.php 2 files changed, 20 insertions(+), 1 deletion(-) Approvals: jenkins-bot: Verified Thiemo Mättig (WMDE): Looks good to me, approved diff --git a/client/includes/RecentChanges/ChangeLineFormatter.php b/client/includes/RecentChanges/ChangeLineFormatter.php index 9e64f2d..39ef17a 100644 --- a/client/includes/RecentChanges/ChangeLineFormatter.php +++ b/client/includes/RecentChanges/ChangeLineFormatter.php @@ -59,7 +59,9 @@ $line .= $this->changeSeparator(); $line .= $flag . ' '; - $line .= Linker::link( $title ); + // @fixme: deprecated method, use \LinkRenderer + $link = Linker::link( $title ); + $line .= "<span class=\"mw-title\">$link</span>"; if ( $changeType !== 'remove' ) { $line .= $this->formatEntityLink( $entityId ); diff --git a/client/tests/phpunit/includes/RecentChanges/ChangeLineFormatterTest.php b/client/tests/phpunit/includes/RecentChanges/ChangeLineFormatterTest.php index 388d717..5e5432f 100644 --- a/client/tests/phpunit/includes/RecentChanges/ChangeLineFormatterTest.php +++ b/client/tests/phpunit/includes/RecentChanges/ChangeLineFormatterTest.php @@ -349,6 +349,15 @@ withClass( 'wikibase-edit' ), havingTextContents( 'D' ) ), + 'edit-titlelink' => both( withTagName( 'a' ) ) + ->andAlso( havingTextContents( 'Canada' ) ), + 'edit-titlelink-wrapper' => allOf( + withTagName( 'span' ), + withClass( 'mw-title' ), + havingChild( + both( withTagName( 'a' ) )->andAlso( havingTextContents( 'Canada' ) ) + ) + ), 'edit-entitylink' => allOf( withTagName( 'a' ), withClass( 'wb-entity-link' ), @@ -442,6 +451,14 @@ ->andAlso( havingTextContents( 'D' ) ), 'delete-titlelink' => both( withTagName( 'a' ) ) ->andAlso( havingTextContents( 'Canada' ) ), + 'delete-titlelink-wrapper' => both( + tagMatchingOutline( '<span class="mw-title"/>' ) + ) + ->andAlso( + havingChild( + both( withTagName( 'a' ) )->andAlso( havingTextContents( 'Canada' ) ) + ) + ), 'delete-changeslist-date' => both( tagMatchingOutline( '<span class="mw-changeslist-date"/>' ) ) -- To view, visit https://gerrit.wikimedia.org/r/379961 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I0f358d8a45235cc456eeefb1e63c8b18505029a7 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Matěj Suchánek <matejsuchane...@gmail.com> Gerrit-Reviewer: Aleksey Bekh-Ivanov (WMDE) <aleksey.bekh-iva...@wikimedia.de> Gerrit-Reviewer: Matěj Suchánek <matejsuchane...@gmail.com> Gerrit-Reviewer: Thiemo Mättig (WMDE) <thiemo.maet...@wikimedia.de> Gerrit-Reviewer: Zoranzoki21 <zorandori4...@gmail.com> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits