Mooeypoo has uploaded a new change for review.
https://gerrit.wikimedia.org/r/307027
Change subject: Style and text fixes for unwatch actions
......................................................................
Style and text fixes for unwatch actions
Bug: T132975
Change-Id: I234b0aeff348b80fa2a9636d7dd182fcd3ef9553
---
M i18n/en.json
M includes/Notifications/FlowPresentationModel.php
M includes/Notifications/PostEditedPresentationModel.php
M includes/Notifications/PostReplyPresentationModel.php
M includes/Notifications/SummaryEditedPresentationModel.php
5 files changed, 14 insertions(+), 12 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Flow
refs/changes/27/307027/1
diff --git a/i18n/en.json b/i18n/en.json
index 9b11510..65d7c3f 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -19,7 +19,7 @@
"notification-dynamic-actions-flow-board-unwatch-confirmation-description":
"This will not affect individual topics you are watching. You can watch [$2
this page] anytime.",
"notification-dynamic-actions-flow-topic-unwatch": "Stop watching this
topic",
"notification-dynamic-actions-flow-topic-unwatch-confirmation": "You
are no longer watching \"$1\"",
-
"notification-dynamic-actions-flow-topic-unwatch-confirmation-description":
"You can watch [$2 this page] anytime.",
+
"notification-dynamic-actions-flow-topic-unwatch-confirmation-description":
"You can watch [$2 this topic] anytime.",
"flow-desc": "Workflow management system",
"flow-talk-taken-over-comment": "/* This page has been converted into a
Flow discussion board */",
"log-name-flow": "Flow activity log",
diff --git a/includes/Notifications/FlowPresentationModel.php
b/includes/Notifications/FlowPresentationModel.php
index 4312e9d..c863039 100644
--- a/includes/Notifications/FlowPresentationModel.php
+++ b/includes/Notifications/FlowPresentationModel.php
@@ -173,6 +173,7 @@
$query = array( 'action' => 'unwatch' );
$link = $this->getWatchActionLink( $title );
$type = $isTopic ? 'topic' : 'board';
+ $stringPageTitle = $isTopic ? $this->getTopicTitle() :
$this->getTruncatedTitleText( $title );
if ( $this->isUserTalkPage() || !$this->getUser()->isWatched(
$title ) ) {
return null;
@@ -185,7 +186,7 @@
'title' => $this
->msg(
'notification-dynamic-actions-flow-' . $type . '-unwatch' )
->params(
- $title->getPrefixedText(),
+ $stringPageTitle,
$title->getFullURL( $query )
)
->parse(),
@@ -196,7 +197,7 @@
'title' => $this
->msg(
'notification-dynamic-actions-flow-' . $type . '-unwatch-confirmation' )
->params(
- $title->getPrefixedText(),
+ $stringPageTitle,
$title->getFullURL()
)
->parse(),
@@ -205,7 +206,7 @@
'description' => $this
->msg(
'notification-dynamic-actions-flow-' . $type .
'-unwatch-confirmation-description' )
->params(
- $title->getPrefixedText(),
+ $stringPageTitle,
$title->getFullURL()
)
->parse(),
diff --git a/includes/Notifications/PostEditedPresentationModel.php
b/includes/Notifications/PostEditedPresentationModel.php
index 9a5722b..f5515d7 100644
--- a/includes/Notifications/PostEditedPresentationModel.php
+++ b/includes/Notifications/PostEditedPresentationModel.php
@@ -39,9 +39,10 @@
$this->getDiffLink( false ),
);
}
+
+ $links[] = $this->getFlowUnwatchDynamicActionLink( true
);
}
- $links[] = $this->getFlowUnwatchDynamicActionLink( true );
return $links;
}
diff --git a/includes/Notifications/PostReplyPresentationModel.php
b/includes/Notifications/PostReplyPresentationModel.php
index 378a1f4..a5e2105 100644
--- a/includes/Notifications/PostReplyPresentationModel.php
+++ b/includes/Notifications/PostReplyPresentationModel.php
@@ -42,14 +42,14 @@
public function getSecondaryLinks() {
if ( $this->isBundled() ) {
- $links = array( $this->getBoardLink() );
+ return array( $this->getBoardLink() );
} else {
- $links = array( $this->getAgentLink(),
$this->getBoardLink() );
+ return array(
+ $this->getAgentLink(),
+ $this->getBoardLink(),
+ $this->getFlowUnwatchDynamicActionLink( true )
+ );
}
-
- $links[] = $this->getFlowUnwatchDynamicActionLink( true );
-
- return $links;
}
protected function getHeaderMessageKey() {
diff --git a/includes/Notifications/SummaryEditedPresentationModel.php
b/includes/Notifications/SummaryEditedPresentationModel.php
index ef93677..c3d3334 100644
--- a/includes/Notifications/SummaryEditedPresentationModel.php
+++ b/includes/Notifications/SummaryEditedPresentationModel.php
@@ -27,9 +27,9 @@
if ( !$this->isFirstRevision() ) {
$links[] = $this->getDiffLink( false );
}
+ $links[] = $this->getFlowUnwatchDynamicActionLink( true
);
}
- $links[] = $this->getFlowUnwatchDynamicActionLink( true );
return $links;
}
--
To view, visit https://gerrit.wikimedia.org/r/307027
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I234b0aeff348b80fa2a9636d7dd182fcd3ef9553
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: Mooeypoo <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits