r101395 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r101394‎ | r101395 | r101396 >
Date:19:59, 31 October 2011
Author:krinkle
Status:ok (Comments)
Tags:
Comment:
[JSTesting] javascripttest-backlink:
* Match the character as used in Skin::subPageSubtitle for regular subpages.
* Instead injecting the message raw, using the message in the escaped form, passing the anchor tag as rawParam
* Follows-up r101345
Modified paths:
  • /branches/JSTesting/includes/specials/SpecialJavaScriptTest.php (modified) (history)
  • /branches/JSTesting/languages/messages/MessagesEn.php (modified) (history)

Diff [purge]

Index: branches/JSTesting/includes/specials/SpecialJavaScriptTest.php
@@ -47,7 +47,9 @@
4848 // Matched! Display proper title and initialize the framework
4949 } elseif ( isset( self::$frameworks[$framework] ) ) {
5050 $out->setPagetitle( wfMsg( 'javascripttest-title', wfMsg( "javascripttest-$framework-name" ) ) );
51 - $out->setSubtitle( wfMsg( 'javascripttest-backlink', Linker::linkKnown( $this->getTitle() ) ) );
 51+ $out->setSubtitle(
 52+ wfMessage( 'javascripttest-backlink' )->rawParams( Linker::linkKnown( $this->getTitle() ) )->escaped()
 53+ );
5254 $this->{self::$frameworks[$framework]}();
5355
5456 // Framework not found, display error
Index: branches/JSTesting/languages/messages/MessagesEn.php
@@ -3372,7 +3372,7 @@
33733373
33743374 # JavaScriptTest
33753375 'javascripttest' => 'JavaScript Test',
3376 -'javascripttest-backlink' => '← $1',
 3376+'javascripttest-backlink' => '< $1',
33773377 'javascripttest-disabled' => 'This function is disabled.',
33783378 'javascripttest-title' => 'Running $1 tests',
33793379 'javascripttest-pagetext-noframework' => 'This page is reserved for running javascript tests.',

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r101345add a backlink on [[Special:JavaScriptTest/qunit]]hashar10:06, 31 October 2011

Comments

#Comment by Hashar (talk | contribs)   20:07, 31 October 2011

The funny arrow ← seems to be used in other *-backlink messages.

The whole Message stuff looks borked to me, most probably because I still have to read the doc :D

#Comment by Krinkle (talk | contribs)   20:44, 31 October 2011

Hm.. indeed. There's 6 other *-backlink messages for core special pages. I like that stricter arrow better (also because in contrary to < it actually is semantically an arrow at all).

How about we change the core one for regular subpages instead ?

Status & tagging log