Cenarium has uploaded a new change for review.
https://gerrit.wikimedia.org/r/325107
Change subject: echo 2
......................................................................
echo 2
Change-Id: If268b0a07d3e8be9ec5acd14dc89a5c767ef494c
---
M backend/FlaggedRevs.hooks.php
M frontend/FlaggedRevsDeferredPresentationModel.php
2 files changed, 18 insertions(+), 21 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/FlaggedRevs
refs/changes/07/325107/1
diff --git a/backend/FlaggedRevs.hooks.php b/backend/FlaggedRevs.hooks.php
index c13db5e..662ed19 100755
--- a/backend/FlaggedRevs.hooks.php
+++ b/backend/FlaggedRevs.hooks.php
@@ -1236,7 +1236,7 @@
'presentation-model' =>
'EchoFlaggedRevsDeferredPresentationModel',
];
$icons['flaggedrevs-deferred'] = [
- 'path' => 'Echo\modules\icons\generic.svg',
+ 'path' => 'Echo\modules\icons\generic.svg', // for now
];
return true;
}
diff --git a/frontend/FlaggedRevsDeferredPresentationModel.php
b/frontend/FlaggedRevsDeferredPresentationModel.php
index 49fae57..9a3dd32 100644
--- a/frontend/FlaggedRevsDeferredPresentationModel.php
+++ b/frontend/FlaggedRevsDeferredPresentationModel.php
@@ -21,22 +21,6 @@
}
public function getPrimaryLink() {
- $helpPage = $this->msg( 'flaggedrevs-defer-help' )->text();
- $helpTitle = Title::newFromText( $helpPage );
- if ( !$helpTitle instanceof Title ) {
- return array();
- }
- return array(
- 'url' => $helpTitle->getLocalURL(),
- 'label' => $this->msg(
'notification-link-text-flaggedrevs-deferred-help' )->text()
- );
- }
-
- public function getSecondaryLinks() {
- return array( $this->getChangesLink(), $this->getLogLink() );
- }
-
- private function getChangesLink() {
$url = $this->event->getTitle()->getLocalURL( array(
'oldid' => $this->event->getExtraParam( 'oldid' ),
'diff' => $this->event->getExtraParam( 'revid' )
@@ -45,10 +29,23 @@
'url' => $url,
'label' => $this->msg(
'notification-link-text-view-changes',
$this->getViewingUserForGender() )->text(),
- 'description' => '',
- 'icon' => 'changes',
- 'prioritized' => true,
);
+ }
+
+ public function getSecondaryLinks() {
+ $links = array( $this->getLogLink() );
+ $helpPage = $this->msg( 'flaggedrevs-defer-help' )->text();
+ $helpTitle = Title::newFromText( $helpPage );
+ if ( $helpTitle instanceof Title ) {
+ $links[] = array(
+ 'url' => $helpTitle->getLocalURL(),
+ 'label' => $this->msg(
'notification-link-text-flaggedrevs-deferred-help' )->text(),
+ 'description' => '',
+ 'icon' => 'help',
+ 'prioritized' => true,
+ );
+ }
+ return $links;
}
private function getLogLink() {
@@ -62,7 +59,7 @@
'label' => $this->msg(
'notification-link-text-flaggedrevs-deferred-log' )->text(),
'url' => SpecialPage::getTitleFor( 'Log' )->getFullURL(
$query ),
'description' => '',
- 'icon' => false,
+ 'icon' => false, // @todo: add a log icon to echo
'prioritized' => true,
);
}
--
To view, visit https://gerrit.wikimedia.org/r/325107
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: If268b0a07d3e8be9ec5acd14dc89a5c767ef494c
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/FlaggedRevs
Gerrit-Branch: master
Gerrit-Owner: Cenarium <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits