private function newItem(AphrontRequest $request, $title, $done, $content)
 {
     $viewer = $request->getUser();
     $box = new PHUIObjectBoxView();
     $header = new PHUIActionHeaderView();
     $header->setHeaderTitle($title);
     if ($done === true) {
         $box->setHeaderColor(PHUIActionHeaderView::HEADER_LIGHTGREEN);
         $header->addAction(id(new PHUIIconView())->setIconFont('fa-check'));
     } else {
         if ($done === false) {
             $box->setHeaderColor(PHUIActionHeaderView::HEADER_LIGHTVIOLET);
             $header->addAction(id(new PHUIIconView())->setIconFont('fa-exclamation'));
         }
     }
     $content = PhabricatorMarkupEngine::renderOneObject(id(new PhabricatorMarkupOneOff())->setContent($content), 'default', $viewer);
     $content = phutil_tag('div', array('class' => 'config-welcome-box-content'), $content);
     $box->setHeader($header);
     $box->appendChild($content);
     return $box;
 }
 private function addPanelHeaderActions(PHUIActionHeaderView $header)
 {
     $panel = $this->getPanel();
     $dashboard_id = $this->getDashboardID();
     $edit_uri = id(new PhutilURI('/dashboard/panel/edit/' . $panel->getID() . '/'));
     if ($dashboard_id) {
         $edit_uri->setQueryParam('dashboardID', $dashboard_id);
     }
     $action_edit = id(new PHUIIconView())->setIconFont('fa-pencil')->setWorkflow(true)->setHref((string) $edit_uri);
     $header->addAction($action_edit);
     if ($dashboard_id) {
         $uri = id(new PhutilURI('/dashboard/removepanel/' . $dashboard_id . '/'))->setQueryParam('panelPHID', $panel->getPHID());
         $action_remove = id(new PHUIIconView())->setIconFont('fa-trash-o')->setHref((string) $uri)->setWorkflow(true);
         $header->addAction($action_remove);
     }
     return $header;
 }