@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Used Cards instead of States for Harbormaster Buildables

Summary: Switched to Obect Cards for better consistency with application search. Added Byline for colorblind/accessability (can move).

Test Plan: Tested my Harbormaster build.

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: epriestley, Korvin

Differential Revision: https://secure.phabricator.com/D8934

+9 -12
+9 -12
src/applications/harbormaster/controller/HarbormasterBuildableListController.php
··· 32 32 $viewer = $this->getRequest()->getUser(); 33 33 34 34 $list = new PHUIObjectItemListView(); 35 - $list->setStates(true); 35 + $list->setCards(true); 36 36 foreach ($buildables as $buildable) { 37 37 $id = $buildable->getID(); 38 38 ··· 55 55 56 56 switch ($buildable->getBuildableStatus()) { 57 57 case HarbormasterBuildable::STATUS_PASSED: 58 - $item->setState(PHUIObjectItemView::STATE_SUCCESS); 58 + $item->setBarColor('green'); 59 + $item->addByline(pht('Build Passed')); 59 60 break; 60 61 case HarbormasterBuildable::STATUS_FAILED: 61 - $item->setState(PHUIObjectItemView::STATE_FAIL); 62 + $item->setBarColor('red'); 63 + $item->addByline(pht('Build Failed')); 62 64 break; 63 65 case HarbormasterBuildable::STATUS_BUILDING: 64 - $item->setState(PHUIObjectItemView::STATE_BUILD); 66 + $item->setBarColor('red'); 67 + $item->addByline(pht('Building')); 65 68 break; 66 - default: 67 - $item->setState(PHUIObjectItemView::STATE_WARN); 68 - break; 69 + 69 70 } 70 71 71 72 $list->addItem($item); 72 73 73 74 } 74 75 75 - $box = id(new PHUIObjectBoxView()) 76 - ->setHeaderText(pht('Buildables')) 77 - ->appendChild($list); 78 - 79 - return $box; 76 + return $list; 80 77 } 81 78 82 79 public function buildSideNavView($for_app = false) {