From 75673a8e3744670be1a02c74e7709f9ec9e53b3d Mon Sep 17 00:00:00 2001 From: Chad Little Date: Thu, 28 May 2015 13:00:26 -0700 Subject: [PATCH] [Redesign] Cleanup Harbormaster UI Summary: Ref T8099, adds StatusIcons in place of barColor. May need to revisit icons. Also fixed incorrect icons used in Drydock. Test Plan: Visit Harbormaster, Drydock, see proper icons. Reviewers: btrahan, epriestley Reviewed By: epriestley Subscribers: Korvin, epriestley Maniphest Tasks: T8099 Differential Revision: https://secure.phabricator.com/D13054 --- src/applications/drydock/view/DrydockLeaseListView.php | 4 ++-- src/applications/drydock/view/DrydockResourceListView.php | 8 ++++---- .../controller/HarbormasterBuildableViewController.php | 4 +++- .../controller/HarbormasterPlanViewController.php | 6 +++--- .../people/controller/PhabricatorPeopleLdapController.php | 6 +++--- 5 files changed, 15 insertions(+), 13 deletions(-) diff --git a/src/applications/drydock/view/DrydockLeaseListView.php b/src/applications/drydock/view/DrydockLeaseListView.php index 40fcfa49be..7d7d8e77ee 100644 --- a/src/applications/drydock/view/DrydockLeaseListView.php +++ b/src/applications/drydock/view/DrydockLeaseListView.php @@ -42,9 +42,9 @@ final class DrydockLeaseListView extends AphrontView { $item->setEpoch($lease->getDateCreated()); if ($lease->isActive()) { - $item->setStatusIcon('fa-dot-circle green'); + $item->setStatusIcon('fa-dot-circle-o green'); } else { - $item->setStatusIcon('fa-dot-circle red'); + $item->setStatusIcon('fa-dot-circle-o red'); } $view->addItem($item); diff --git a/src/applications/drydock/view/DrydockResourceListView.php b/src/applications/drydock/view/DrydockResourceListView.php index e8921b21c9..92ec762b81 100644 --- a/src/applications/drydock/view/DrydockResourceListView.php +++ b/src/applications/drydock/view/DrydockResourceListView.php @@ -27,16 +27,16 @@ final class DrydockResourceListView extends AphrontView { switch ($resource->getStatus()) { case DrydockResourceStatus::STATUS_PENDING: - $item->setStatusIcon('fa-dot-circle yellow'); + $item->setStatusIcon('fa-dot-circle-o yellow'); break; case DrydockResourceStatus::STATUS_OPEN: - $item->setStatusIcon('fa-dot-circle green'); + $item->setStatusIcon('fa-dot-circle-o green'); break; case DrydockResourceStatus::STATUS_DESTROYED: - $item->setStatusIcon('fa-times-circle black'); + $item->setStatusIcon('fa-times-circle-o black'); break; default: - $item->setStatusIcon('fa-dot-circle red'); + $item->setStatusIcon('fa-dot-circle-o red'); break; } diff --git a/src/applications/harbormaster/controller/HarbormasterBuildableViewController.php b/src/applications/harbormaster/controller/HarbormasterBuildableViewController.php index ecb7605657..c3a5817994 100644 --- a/src/applications/harbormaster/controller/HarbormasterBuildableViewController.php +++ b/src/applications/harbormaster/controller/HarbormasterBuildableViewController.php @@ -175,7 +175,9 @@ final class HarbormasterBuildableViewController ->setHref($view_uri); $status = $build->getBuildStatus(); - $item->setBarColor(HarbormasterBuild::getBuildStatusColor($status)); + $item->setStatusIcon( + 'fa-dot-circle-o '.HarbormasterBuild::getBuildStatusColor($status), + HarbormasterBuild::getBuildStatusName($status)); $item->addAttribute(HarbormasterBuild::getBuildStatusName($status)); diff --git a/src/applications/harbormaster/controller/HarbormasterPlanViewController.php b/src/applications/harbormaster/controller/HarbormasterPlanViewController.php index 7447f2ed7b..e7f34ce551 100644 --- a/src/applications/harbormaster/controller/HarbormasterPlanViewController.php +++ b/src/applications/harbormaster/controller/HarbormasterPlanViewController.php @@ -122,7 +122,7 @@ final class HarbormasterPlanViewController extends HarbormasterPlanController { $item = id(new PHUIObjectItemView()) ->setObjectName(pht('Step %d.%d', $depth, $i)) ->setHeader(pht('Unknown Implementation')) - ->setBarColor('red') + ->setStatusIcon('fa-warning red') ->addAttribute(pht( 'This step has an invalid implementation (%s).', $step->getClassName())) @@ -208,7 +208,7 @@ final class HarbormasterPlanViewController extends HarbormasterPlanController { if ($has_conflicts) { $has_any_conflicts = true; - $item->setBarColor('red'); + $item->setStatusIcon('fa-warning red'); } if ($run_ref['cycle']) { @@ -216,7 +216,7 @@ final class HarbormasterPlanViewController extends HarbormasterPlanController { } if ($is_deadlocking) { - $item->setBarColor('red'); + $item->setStatusIcon('fa-warning red'); } $step_list->addItem($item); diff --git a/src/applications/people/controller/PhabricatorPeopleLdapController.php b/src/applications/people/controller/PhabricatorPeopleLdapController.php index 6f5fa09f3f..2e030ad580 100644 --- a/src/applications/people/controller/PhabricatorPeopleLdapController.php +++ b/src/applications/people/controller/PhabricatorPeopleLdapController.php @@ -101,17 +101,17 @@ final class PhabricatorPeopleLdapController $header = pht('Successfully added %s', $username); $attribute = null; - $color = 'green'; + $color = 'fa-check green'; } catch (Exception $ex) { $header = pht('Failed to add %s', $username); $attribute = $ex->getMessage(); - $color = 'red'; + $color = 'fa-times red'; } $item = id(new PHUIObjectItemView()) ->setHeader($header) ->addAttribute($attribute) - ->setBarColor($color); + ->setStatusIcon($color); $list->addItem($item); }