diff --git a/src/applications/project/controller/PhabricatorProjectProfileController.php b/src/applications/project/controller/PhabricatorProjectProfileController.php index ef2c6ad4fe..d10998444c 100644 --- a/src/applications/project/controller/PhabricatorProjectProfileController.php +++ b/src/applications/project/controller/PhabricatorProjectProfileController.php @@ -59,11 +59,19 @@ final class PhabricatorProjectProfileController $header = id(new PHUIHeaderView()) ->setHeader($project->getName()) - ->setSubheader(phutil_utf8_shorten($profile->getBlurb(), 1024)) + ->setUser($user) + ->setPolicyObject($project) ->setImage($picture); + if ($project->getStatus() == PhabricatorProjectStatus::STATUS_ACTIVE) { + $header->setStatus('oh-ok', '', pht('Active')); + } else { + $header->setStatus('policy-noone', '', pht('Archived')); + } + + $actions = $this->buildActionListView($project); - $properties = $this->buildPropertyListView($project, $actions); + $properties = $this->buildPropertyListView($project, $profile, $actions); $crumbs = $this->buildApplicationCrumbs(); $crumbs->addCrumb( @@ -253,6 +261,7 @@ final class PhabricatorProjectProfileController private function buildPropertyListView( PhabricatorProject $project, + PhabricatorProjectProfile $profile, PhabricatorActionListView $actions) { $request = $this->getRequest(); $viewer = $request->getUser(); @@ -266,6 +275,13 @@ final class PhabricatorProjectProfileController pht('Created'), phabricator_datetime($project->getDateCreated(), $viewer)); + $view->addSectionHeader(pht('Description')); + $view->addTextContent( + PhabricatorMarkupEngine::renderOneObject( + id(new PhabricatorMarkupOneOff())->setContent($profile->getBlurb()), + 'default', + $viewer)); + return $view; } diff --git a/src/applications/project/controller/PhabricatorProjectProfileEditController.php b/src/applications/project/controller/PhabricatorProjectProfileEditController.php index ec5419a6de..3b57e1b907 100644 --- a/src/applications/project/controller/PhabricatorProjectProfileEditController.php +++ b/src/applications/project/controller/PhabricatorProjectProfileEditController.php @@ -127,8 +127,8 @@ final class PhabricatorProjectProfileEditController ->setOptions($options) ->setValue($project->getStatus())) ->appendChild( - id(new AphrontFormTextAreaControl()) - ->setLabel(pht('Blurb')) + id(new PhabricatorRemarkupControl()) + ->setLabel(pht('Description')) ->setName('blurb') ->setValue($profile->getBlurb())) ->appendChild(