Siebrand has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/68649


Change subject: Update formatting
......................................................................

Update formatting

Change-Id: Ie531f0151073d580e8c92efb767f417ebeec13bb
---
M Autoload.php
M MainPage.php
M ResourceLoaderProjectIconsModule.php
M specials/SpecialTwnMainPage.php
4 files changed, 41 insertions(+), 16 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TwnMainPage 
refs/changes/49/68649/1

diff --git a/Autoload.php b/Autoload.php
index db05eff..fc7a91c 100644
--- a/Autoload.php
+++ b/Autoload.php
@@ -15,4 +15,3 @@
 $wgAutoloadClasses['ResourceLoaderProjectIconsModule'] = 
"$dir/ResourceLoaderProjectIconsModule.php";
 $wgAutoloadClasses['UserStats'] = "$dir/UserStats.php";
 $wgAutoloadClasses['SpecialTwnMainPage'] = 
"$dir/specials/SpecialTwnMainPage.php";
-
diff --git a/MainPage.php b/MainPage.php
index c81be12..fcf1039 100644
--- a/MainPage.php
+++ b/MainPage.php
@@ -39,7 +39,8 @@
        global $wgMainPageImages, $wgExtensionAssetsPath;
        $wgMainPageImages[] = array(
                'url' => 
"$wgExtensionAssetsPath/TwnMainPage/resources/banners/dance.jpg",
-               'attribution' => '<a 
href="http://www.flickr.com/photos/ldhendrix/7389351416/";>CC-BY ldhendrix</a>',
+               'attribution' => '<a 
href="http://www.flickr.com/photos/ldhendrix/7389351416/";>' .
+                       'CC-BY ldhendrix</a>',
        );
 
        return true;
diff --git a/ResourceLoaderProjectIconsModule.php 
b/ResourceLoaderProjectIconsModule.php
index 0cdacf5..2609183 100644
--- a/ResourceLoaderProjectIconsModule.php
+++ b/ResourceLoaderProjectIconsModule.php
@@ -20,7 +20,7 @@
        protected function getData() {
                $projects = ProjectHandler::getProjects();
                $icons = array();
-               foreach( $projects as $group ) {
+               foreach ( $projects as $group ) {
                        wfSuppressWarnings();
                        $icons[$group->getId()] = TranslateUtils::getIcon( 
$group, 100 );
                        wfRestoreWarnings();
@@ -60,7 +60,6 @@
 }
 
 CSS;
-
                        }
                }
 
@@ -87,6 +86,7 @@
                        'hash' => $hash,
                        'timestamp' => $timestamp,
                ) );
+
                return $timestamp;
        }
 }
diff --git a/specials/SpecialTwnMainPage.php b/specials/SpecialTwnMainPage.php
index f9bd0d9..53a5a54 100644
--- a/specials/SpecialTwnMainPage.php
+++ b/specials/SpecialTwnMainPage.php
@@ -178,9 +178,8 @@
                $label = htmlspecialchars( $group->getLabel( 
$this->getContext() ) );
                $stats = $statsbar->getHtml( $this->getContext() );
                // @todo FIXME i18n: Hard coded percentage character twice.
-               $acts =
-                       Html::element( 'span', array( 'class' => 'translate' ), 
"$translated%" ) .
-                               Html::element( 'span', array( 'class' => 
'proofread' ), "$proofread%" );
+               $acts = Html::element( 'span', array( 'class' => 'translate' ), 
"$translated%" ) .
+                       Html::element( 'span', array( 'class' => 'proofread' ), 
"$proofread%" );
 
                $title = SpecialPage::getTitleFor( 'Translate' );
                $translate = Html::element( 'a', array(
@@ -412,19 +411,28 @@
 
                $out .= Html::hidden( 'wpSandboxToken', 
ApiTranslateSandbox::getToken() );
                $out .= Html::element( 'h1', $row, $this->msg( 
'twnmp-become-translator' )->text() );
-               $out .= Html::element( 'h2', $row, $this->msg( 
'twnmp-choose-languages-you-know' )->text() );
+               $out .= Html::element(
+                       'h2',
+                       $row,
+                       $this->msg( 'twnmp-choose-languages-you-know' )->text()
+               );
                $out .= Xml::checkLabel( $languageName, 'wpLanguage1', 
'wpLanguage1', true );
                $out .= Html::openElement( 'div', $row );
                $out .= Html::element( 'div', array(
                        'class' => 'eight columns offset-by-one 
signup-language-selector'
                ), $this->msg( 'twnmp-choose-another-language' )->text() );
                $out .= Html::closeElement( 'div' );
-               $out .= Html::element( 'h2', $row, $this->msg( 
'twnmp-choose-fill-account-details' )->text() );
+               $out .= Html::element(
+                       'h2',
+                       $row,
+                       $this->msg( 'twnmp-choose-fill-account-details' 
)->text()
+               );
                $out .= Html::openElement( 'div', $row );
                $out .= Html::element( 'input', array(
                        'class' => 'eleven columns',
                        'name' => 'wpName',
-                       'placeholder' => $this->msg( 
'twnmp-signup-username-placeholder' )->text(), // @todo IE doesn't support 
placeholders
+                       // @todo IE doesn't support placeholders
+                       'placeholder' => $this->msg( 
'twnmp-signup-username-placeholder' )->text(),
                ) );
                $out .= Html::closeElement( 'div' );
 
@@ -433,7 +441,8 @@
                        'class' => 'eleven columns',
                        'name' => 'wpPassword',
                        'type' => 'password',
-                       'placeholder' => $this->msg( 
'twnmp-signup-password-placeholder' )->text(), // @todo IE doesn't support 
placeholders
+                       // @todo IE doesn't support placeholders
+                       'placeholder' => $this->msg( 
'twnmp-signup-password-placeholder' )->text(),
                ) );
                $out .= Html::closeElement( 'div' );
 
@@ -442,7 +451,8 @@
                        'class' => 'eleven columns',
                        'name' => 'wpEmail',
                        'type' => 'email',
-                       'placeholder' => $this->msg( 
'twnmp-signup-email-placeholder' )->text(), // @todo IE doesn't support 
placeholders
+                       // @todo IE doesn't support placeholders
+                       'placeholder' => $this->msg( 
'twnmp-signup-email-placeholder' )->text(),
                ) );
                $out .= Html::closeElement( 'div' );
 
@@ -468,10 +478,17 @@
                );
                $statsArray = $cacher->get();
 
-               $out = Html::openElement( 'div', array( 'class' => 'five 
columns main-widget stats-widget' ) );
+               $out = Html::openElement(
+                       'div',
+                       array( 'class' => 'five columns main-widget 
stats-widget' )
+               );
 
                $out .= Html::openElement( 'div', array( 'class' => 'row 
user-stats-title' ) );
-               $out .= Html::element( 'h2', array(), $this->msg( 
'twnmp-your-translations-stats' )->text() );
+               $out .= Html::element(
+                       'h2',
+                       array(),
+                       $this->msg( 'twnmp-your-translations-stats' )->text()
+               );
                $out .= Html::element( 'div', array(), $languageName );
                $out .= Html::closeElement( 'div' );
 
@@ -490,7 +507,11 @@
                foreach ( $stats as $user => $count ) {
                        if ( $user === $myuser ) {
                                $out .= Html::element( 'div', array( 'class' => 
'count' ), $count );
-                               $out .= Html::element( 'div', array( 'class' => 
'count-description' ), $this->msg( 'twnmp-translations-per-month' )->text() );
+                               $out .= Html::element(
+                                       'div',
+                                       array( 'class' => 'count-description' ),
+                                       $this->msg( 
'twnmp-translations-per-month' )->text()
+                               );
 
                                $msg = $this->msg( 
'twnmp-translations-translator-ranking' )
                                        ->params( $myuser, $i, $translators, 
$languageName )
@@ -524,7 +545,11 @@
                foreach ( $stats as $user => $count ) {
                        if ( $user === $myuser ) {
                                $out .= Html::element( 'div', array( 'class' => 
'count' ), $count );
-                               $out .= Html::element( 'div', array( 'class' => 
'count-description' ), $this->msg( 'twnmp-reviews-per-month' )->text() );
+                               $out .= Html::element(
+                                       'div',
+                                       array( 'class' => 'count-description' ),
+                                       $this->msg( 'twnmp-reviews-per-month' 
)->text()
+                               );
 
                                $msg = $this->msg( 
'twnmp-translations-translator-ranking' )
                                        ->params( $myuser, $i, $translators, 
$languageName )

-- 
To view, visit https://gerrit.wikimedia.org/r/68649
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie531f0151073d580e8c92efb767f417ebeec13bb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TwnMainPage
Gerrit-Branch: master
Gerrit-Owner: Siebrand <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to