Umherirrender has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/364108 )
Change subject: Break long line
......................................................................
Break long line
Exclude one file, because it is using <<<TEXT, which can not be shorten
Change-Id: Id6ee38af6372f807a496c7fa5d33b4f22436eaf4
---
M includes/TwoColConflictPage.php
M phpcs.xml
2 files changed, 29 insertions(+), 20 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TwoColConflict
refs/changes/08/364108/1
diff --git a/includes/TwoColConflictPage.php b/includes/TwoColConflictPage.php
index 29eec16..13fed0a 100644
--- a/includes/TwoColConflictPage.php
+++ b/includes/TwoColConflictPage.php
@@ -55,7 +55,8 @@
$this->addCSS();
$this->addJS();
$this->deactivateWikEd();
- $this->editFormTextTop = '<div
class="mw-twocolconflict-form mw-twocolconflict-before-base-selection">';
+ $this->editFormTextTop =
+ '<div class="mw-twocolconflict-form
mw-twocolconflict-before-base-selection">';
$this->editFormTextBottom = '</div>';
$this->editFormTextBeforeContent =
$this->addEditFormBeforeContent();
$this->editFormTextAfterContent =
$this->addEditFormAfterContent();
@@ -122,10 +123,11 @@
$out .= '<ul>';
$out .= '';
$out .= '<li><span class="mw-twocolconflict-lastuser">' .
- $this->getContext()->msg(
'twoColConflict-changes-col-desc-2' )->text() . '</span><br/>' .
- $this->buildEditSummary() . '</li>';
+ $this->getContext()->msg(
'twoColConflict-changes-col-desc-2' )->text() .
+ '</span><br/>' . $this->buildEditSummary() . '</li>';
$out .= '<li><span class="mw-twocolconflict-user">' .
- $this->getContext()->msg(
'twoColConflict-changes-col-desc-4' )->text() . '</span></li>';
+ $this->getContext()->msg(
'twoColConflict-changes-col-desc-4' )->text() .
+ '</span></li>';
$out .= '</ul>';
$out .= '</div>';
$out .= '</div>';
@@ -298,14 +300,20 @@
$out .= '<div class="mw-twocolconflict-col-desc">';
$out .= '<div class="mw-twocolconflict-edit-desc">';
$out .= '<p>' . $this->getContext()->msg(
'twoColConflict-editor-col-desc-1' ) . '</p>';
- $out .= '<p>'
- . $this->getContext()->msg(
'twoColConflict-editor-col-desc-2', $this->getSubmitButtonLabel() ) . '</p>';
+ $out .= '<p>' .
+ $this->getContext()->msg(
+ 'twoColConflict-editor-col-desc-2',
$this->getSubmitButtonLabel()
+ ) . '</p>';
$out .= '</div>';
$out .= '<ol class="mw-twocolconflict-base-selection-desc">';
- $out .= '<li>' . $this->getContext()->msg(
'twoColConflict-base-selection-desc-1' ) . '</li>';
- $out .= '<li>' . $this->getContext()->msg(
'twoColConflict-base-selection-desc-2' ) . '</li>';
+ $out .= '<li>' . $this->getContext()->msg(
'twoColConflict-base-selection-desc-1' ) .
+ '</li>';
+ $out .= '<li>' . $this->getContext()->msg(
'twoColConflict-base-selection-desc-2' ) .
+ '</li>';
$out .= '<li>'
- . $this->getContext()->msg(
'twoColConflict-base-selection-desc-3', $this->getSubmitButtonLabel() ) .
'</li>';
+ . $this->getContext()->msg(
+ 'twoColConflict-base-selection-desc-3',
$this->getSubmitButtonLabel()
+ ) . '</li>';
$out .= '</ol></div></div>';
return $out;
@@ -527,7 +535,9 @@
'</span>' .
( count( $lines ) > 1 ? "\n" :
$this->getContext()->msg( 'word-separator' ) ) .
'<span
class="mw-twocolconflict-diffchange-fadeout-start">' .
- htmlspecialchars( $this->trimStringToFullWord(
array_pop( $lines ), $maxLength / 2, false ) ) .
+ htmlspecialchars(
+ $this->trimStringToFullWord( array_pop( $lines
), $maxLength / 2, false )
+ ) .
'</span>';
}
@@ -599,11 +609,12 @@
}
private function addJS() {
- $this->context->getOutput()->addJsConfigVars(
'wgTwoColConflict', 'true' );
- $this->context->getOutput()->addJsConfigVars(
'wgTwoColConflictWikiEditor', $this->wikiEditorIsEnabled() );
- $this->context->getOutput()->addJsConfigVars(
'wgTwoColConflictSubmitLabel', $this->getSubmitButtonLabel() );
+ $out = $this->context->getOutput();
+ $out->addJsConfigVars( 'wgTwoColConflict', 'true' );
+ $out->addJsConfigVars( 'wgTwoColConflictWikiEditor',
$this->wikiEditorIsEnabled() );
+ $out->addJsConfigVars( 'wgTwoColConflictSubmitLabel',
$this->getSubmitButtonLabel() );
- $this->context->getOutput()->addModules( [
+ $out->addModules( [
'ext.TwoColConflict.initJs',
'ext.TwoColConflict.filterOptionsJs'
] );
diff --git a/phpcs.xml b/phpcs.xml
index 4bbcb8c..03b9bbd 100644
--- a/phpcs.xml
+++ b/phpcs.xml
@@ -4,13 +4,11 @@
<exclude
name="MediaWiki.Commenting.FunctionComment.MissingParamComment" />
<exclude
name="MediaWiki.NamingConventions.LowerCamelFunctionsName.FunctionName" />
</rule>
+ <rule ref="Generic.Files.LineLength">
+
<exclude-pattern>tests/phpunit/includes/LineBasedUnifiedDiffFormatterTest.php</exclude-pattern>
+ </rule>
<file>.</file>
<arg name="extensions" value="php,php5,inc" />
- <arg name="encoding" value="utf8" />
+ <arg name="encoding" value="UTF-8" />
<exclude-pattern>vendor</exclude-pattern>
- <rule ref="Generic.Files.LineLength">
- <properties>
- <property name="lineLimit" value="115" />
- </properties>
- </rule>
</ruleset>
--
To view, visit https://gerrit.wikimedia.org/r/364108
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Id6ee38af6372f807a496c7fa5d33b4f22436eaf4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TwoColConflict
Gerrit-Branch: master
Gerrit-Owner: Umherirrender <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits