Manual:$wgRecentChangesFlags/zh

From Linux Web Expert

Revision as of 06:30, 8 April 2024 by 122.100.88.89 (talk)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

<translate> Recent changes, new pages, watchlist and history</translate>: $wgRecentChangesFlags
Flags (letter symbols) shown in recent changes and watchlist to indicate certain types of edits.
<translate> Introduced in version:</translate>1.22.0 (Gerrit change 66038; git #bb0ab45e)
<translate> Removed in version:</translate><translate> still in use</translate>
<translate> Allowed values:</translate>(数组)
<translate> Default value:</translate>(参见下方)

Details

  • The 'letter' key is a message, which is used as text of the abbr.
  • The 'title' key is a message, which is used as title attribute of the abbr.
  • The optional 'class' key allows to set a CSS class different than the flag name.
  • The optional 'grouping' key allows to set how top-level flag is determined.
    • 'any' will set the top-level flag if any line contains the flag.
    • 'all' will only be set if all lines contain the flag.

Default value

MediaWiki版本:
<translate> ≥</translate> 1.27
$wgRecentChangesFlags = [
	'newpage' => [
		'letter' => 'newpageletter',
		'title' => 'recentchanges-label-newpage',
		'legend' => 'recentchanges-legend-newpage',
		'grouping' => 'any',
	],
	'minor' => [
		'letter' => 'minoreditletter',
		'title' => 'recentchanges-label-minor',
		'legend' => 'recentchanges-legend-minor',
		'class' => 'minoredit',
		'grouping' => 'all',
	],
	'bot' => [
		'letter' => 'boteditletter',
		'title' => 'recentchanges-label-bot',
		'legend' => 'recentchanges-legend-bot',
		'class' => 'botedit',
		'grouping' => 'all',
	],
	'unpatrolled' => [
		'letter' => 'unpatrolledletter',
		'title' => 'recentchanges-label-unpatrolled',
		'legend' => 'recentchanges-legend-unpatrolled',
		'grouping' => 'any',
	],
];
<td class="mw-version-versionbox" title="<translate nowrap> MediaWiki <tvar name=1>1.26</tvar> is unsupported version</translate>">
1.24 – 1.26
<translate> MediaWiki versions:</translate>
$wgRecentChangesFlags = array(
	'newpage' => array(
		'letter' => 'newpageletter',
		'title' => 'recentchanges-label-newpage',
		'legend' => 'recentchanges-legend-newpage',
	),
	'minor' => array(
		'letter' => 'minoreditletter',
		'title' => 'recentchanges-label-minor',
		'legend' => 'recentchanges-legend-minor',
		'class' => 'minoredit',
	),
	'bot' => array(
		'letter' => 'boteditletter',
		'title' => 'recentchanges-label-bot',
		'legend' => 'recentchanges-legend-bot',
		'class' => 'botedit',
	),
	'unpatrolled' => array(
		'letter' => 'unpatrolledletter',
		'title' => 'recentchanges-label-unpatrolled',
		'legend' => 'recentchanges-legend-unpatrolled',
	),
);
<td class="mw-version-versionbox" title="<translate nowrap> MediaWiki <tvar name=1>1.23</tvar> is unsupported version</translate>">
1.22 – 1.23
<translate> MediaWiki versions:</translate>
$wgRecentChangesFlags = array(
	'newpage' => array( 'letter' => 'newpageletter',
		'title' => 'recentchanges-label-newpage' ),
	'minor' => array( 'letter' => 'minoreditletter',
		'title' => 'recentchanges-label-minor', 'class' => 'minoredit' ),
	'bot' => array( 'letter' => 'boteditletter',
		'title' => 'recentchanges-label-bot', 'class' => 'botedit' ),
	'unpatrolled' => array( 'letter' => 'unpatrolledletter',
		'title' => 'recentchanges-label-unpatrolled' ),
);

See also