Render Remarkup poorly in Phame Feed stories
Summary: Seeing if this is the correct path, then will apply in Pholio, Ponder. Test Plan: epriestley Reviewers: epriestley Reviewed By: epriestley Subscribers: joshuaspence, Korvin Maniphest Tasks: T9825 Differential Revision: https://secure.phabricator.com/D14646
This commit is contained in:
@@ -185,7 +185,7 @@ final class PhamePostTransaction
|
|||||||
return parent::getTitleForFeed();
|
return parent::getTitleForFeed();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getBodyForFeed(PhabricatorFeedStory $story) {
|
public function getRemarkupBodyForFeed(PhabricatorFeedStory $story) {
|
||||||
$text = null;
|
$text = null;
|
||||||
switch ($this->getTransactionType()) {
|
switch ($this->getTransactionType()) {
|
||||||
case self::TYPE_TITLE:
|
case self::TYPE_TITLE:
|
||||||
@@ -205,11 +205,7 @@ final class PhamePostTransaction
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (strlen($text)) {
|
return $text;
|
||||||
return PhabricatorMarkupEngine::summarize($text);
|
|
||||||
}
|
|
||||||
|
|
||||||
return parent::getBodyForFeed($story);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getColor() {
|
public function getColor() {
|
||||||
|
|||||||
@@ -964,6 +964,12 @@ abstract class PhabricatorApplicationTransaction
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function getBodyForFeed(PhabricatorFeedStory $story) {
|
public function getBodyForFeed(PhabricatorFeedStory $story) {
|
||||||
|
$remarkup = $this->getRemarkupBodyForFeed($story);
|
||||||
|
if ($remarkup !== null) {
|
||||||
|
$remarkup = PhabricatorMarkupEngine::summarize($remarkup);
|
||||||
|
return new PHUIRemarkupView($this->viewer, $remarkup);
|
||||||
|
}
|
||||||
|
|
||||||
$old = $this->getOldValue();
|
$old = $this->getOldValue();
|
||||||
$new = $this->getNewValue();
|
$new = $this->getNewValue();
|
||||||
|
|
||||||
@@ -981,6 +987,10 @@ abstract class PhabricatorApplicationTransaction
|
|||||||
return $body;
|
return $body;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getRemarkupBodyForFeed(PhabricatorFeedStory $story) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
public function getActionStrength() {
|
public function getActionStrength() {
|
||||||
if ($this->isInlineCommentTransaction()) {
|
if ($this->isInlineCommentTransaction()) {
|
||||||
return 0.25;
|
return 0.25;
|
||||||
|
|||||||
Reference in New Issue
Block a user