Matmarex has uploaded a new change for review.
https://gerrit.wikimedia.org/r/72984
Change subject: Show small explanation next to lists of tags
......................................................................
Show small explanation next to lists of tags
Lists of tags are shown on recent changes, watchlists, history pages
and diffs. However, it's hard to tell what they are, as they have no
visual indicators and resemble edit summaries (they looks examply the
same sans the italics). Wikimedia wikis have been using various
methods to remedy that (a "Tag:" prefix in every tag message, yellow
background color, etc.).
This basically implements the first one: a link to Special:Tags and
"Tag(s):" text is shown before the list of tags everywhere it's shown.
The text is correctly pluralized depending on the number of tags given
revision has.
Change-Id: If21eaed4171e732daaee32087c3307d70b60d81f
---
M includes/ChangeTags.php
M languages/messages/MessagesEn.php
M languages/messages/MessagesQqq.php
M maintenance/language/messages.inc
4 files changed, 11 insertions(+), 1 deletion(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/84/72984/1
diff --git a/includes/ChangeTags.php b/includes/ChangeTags.php
index 5478396..32440f5 100644
--- a/includes/ChangeTags.php
+++ b/includes/ChangeTags.php
@@ -54,7 +54,10 @@
);
$classes[] = Sanitizer::escapeClass( "mw-tag-$tag" );
}
- $markers = wfMessage( 'parentheses' )->rawParams(
$wgLang->commaList( $displayTags ) )->text();
+ $markers = wfMessage( 'tag-list-wrapper' )
+ ->numParams( count( $displayTags ) )
+ ->rawParams( $wgLang->commaList( $displayTags ) )
+ ->parse();
$markers = Xml::tags( 'span', array( 'class' =>
'mw-tag-markers' ), $markers );
return array( $markers, $classes );
diff --git a/languages/messages/MessagesEn.php
b/languages/messages/MessagesEn.php
index d675e17..d747756 100644
--- a/languages/messages/MessagesEn.php
+++ b/languages/messages/MessagesEn.php
@@ -4893,6 +4893,7 @@
'tags-summary' => '', # do not translate or duplicate this message
to other languages
'tag-filter' => '[[Special:Tags|Tag]] filter:',
'tag-filter-submit' => 'Filter',
+'tag-list-wrapper' => '([[Special:Tags|{{PLURAL:$1|Tag|Tags}}]]: $2)',
'tags-title' => 'Tags',
'tags-intro' => 'This page lists the tags that the software may
mark an edit with, and their meaning.',
'tags-tag' => 'Tag name',
diff --git a/languages/messages/MessagesQqq.php
b/languages/messages/MessagesQqq.php
index 7582c6c..a7a612a 100644
--- a/languages/messages/MessagesQqq.php
+++ b/languages/messages/MessagesQqq.php
@@ -8789,6 +8789,11 @@
'tag-filter-submit' => 'Caption of the submit button displayed next to the tag
filter on lists of changes (e.g. [[Special:Log]], [[Special:Contributions]],
[[Special:Newpages]], [[Special:Recentchanges]],
[[Special:Recentchangeslinked]], page histories)
{{Identical|Filter}}',
+'tag-list-wrapper' => 'Wrapper for the list of tags shown on recent changes,
watchlists, history pages and diffs.
+
+Parameters:
+* $1 - number of distinct tags for given edit
+* $2 - comma-separated list of tags for given edit',
'tags-title' => 'The title of [[Special:Tags]]',
'tags-intro' => 'Explanation on top of [[Special:Tags]]. For more information
on tags see [[mw:Manual:Tags|MediaWiki]].',
'tags-tag' => 'Caption of a column in [[Special:Tags]]. For more information
on tags see [[mw:Manual:Tags|MediaWiki]].',
diff --git a/maintenance/language/messages.inc
b/maintenance/language/messages.inc
index 2cb94cf..9328144 100644
--- a/maintenance/language/messages.inc
+++ b/maintenance/language/messages.inc
@@ -3732,6 +3732,7 @@
'tags-summary',
'tag-filter',
'tag-filter-submit',
+ 'tag-list-wrapper',
'tags-title',
'tags-intro',
'tags-tag',
--
To view, visit https://gerrit.wikimedia.org/r/72984
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: If21eaed4171e732daaee32087c3307d70b60d81f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Matmarex <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits