@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.

Add FontIcons to PHUIObjectItemView

Summary: Added generic FontIcons for PHUIObjectItemView, used in Almanac Console. Simplified States.

Test Plan:
Almanac Console, UIExamples

Reviewers: btrahan, epriestley

Reviewed By: epriestley

Subscribers: Korvin, epriestley

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

+32 -40
+3 -3
resources/celerity/map.php
··· 7 7 */ 8 8 return array( 9 9 'names' => array( 10 - 'core.pkg.css' => 'e6383567', 10 + 'core.pkg.css' => '3d6955ad', 11 11 'core.pkg.js' => 'df35fdde', 12 12 'darkconsole.pkg.js' => '8ab24e01', 13 13 'differential.pkg.css' => '8af45893', ··· 136 136 'rsrc/css/phui/phui-info-panel.css' => '27ea50a1', 137 137 'rsrc/css/phui/phui-list.css' => '53deb25c', 138 138 'rsrc/css/phui/phui-object-box.css' => '0d47b3c8', 139 - 'rsrc/css/phui/phui-object-item-list-view.css' => 'd2f441c9', 139 + 'rsrc/css/phui/phui-object-item-list-view.css' => '10297907', 140 140 'rsrc/css/phui/phui-pinboard-view.css' => '3dd4a269', 141 141 'rsrc/css/phui/phui-property-list-view.css' => '51480060', 142 142 'rsrc/css/phui/phui-remarkup-preview.css' => '19ad512b', ··· 779 779 'phui-info-panel-css' => '27ea50a1', 780 780 'phui-list-view-css' => '53deb25c', 781 781 'phui-object-box-css' => '0d47b3c8', 782 - 'phui-object-item-list-view-css' => 'd2f441c9', 782 + 'phui-object-item-list-view-css' => '10297907', 783 783 'phui-pinboard-view-css' => '3dd4a269', 784 784 'phui-property-list-view-css' => '51480060', 785 785 'phui-remarkup-preview-css' => '19ad512b',
+10 -2
src/applications/almanac/controller/AlmanacConsoleController.php
··· 10 10 $viewer = $request->getViewer(); 11 11 12 12 $menu = id(new PHUIObjectItemListView()) 13 - ->setUser($viewer); 13 + ->setUser($viewer) 14 + ->setStackable(true); 14 15 15 16 $menu->addItem( 16 17 id(new PHUIObjectItemView()) 17 18 ->setHeader(pht('Services')) 18 19 ->setHref($this->getApplicationURI('service/')) 20 + ->setFontIcon('fa-plug') 19 21 ->addAttribute( 20 22 pht( 21 23 'Manage Almanac services.'))); ··· 24 26 id(new PHUIObjectItemView()) 25 27 ->setHeader(pht('Devices')) 26 28 ->setHref($this->getApplicationURI('device/')) 29 + ->setFontIcon('fa-server') 27 30 ->addAttribute( 28 31 pht( 29 32 'Manage Almanac devices.'))); ··· 32 35 id(new PHUIObjectItemView()) 33 36 ->setHeader(pht('Networks')) 34 37 ->setHref($this->getApplicationURI('network/')) 38 + ->setFontIcon('fa-globe') 35 39 ->addAttribute( 36 40 pht( 37 41 'Manage Almanac networks.'))); ··· 39 43 $crumbs = $this->buildApplicationCrumbs(); 40 44 $crumbs->addTextCrumb(pht('Console')); 41 45 46 + $box = id(new PHUIObjectBoxView()) 47 + ->setHeaderText('Console') 48 + ->appendChild($menu); 49 + 42 50 return $this->buildApplicationPage( 43 51 array( 44 52 $crumbs, 45 - $menu, 53 + $box, 46 54 ), 47 55 array( 48 56 'title' => pht('Almanac Console'),
+15 -10
src/view/phui/PHUIObjectItemView.php
··· 144 144 $fi = 'fa-refresh ph-spin sky'; 145 145 break; 146 146 } 147 + $this->setFontIcon($fi); 148 + return $this; 149 + } 150 + 151 + public function setFontIcon($icon) { 147 152 $this->fontIcon = id(new PHUIIconView()) 148 - ->setIconFont($fi.' fa-2x'); 153 + ->setIconFont($icon); 149 154 return $this; 150 155 } 151 156 ··· 537 542 $this->getImageIcon()); 538 543 } 539 544 540 - if ($image && $this->href) { 541 - $image = phutil_tag( 542 - 'a', 543 - array( 544 - 'href' => $this->href, 545 - ), 546 - $image); 547 - } 548 - 549 545 $ficon = null; 550 546 if ($this->fontIcon) { 551 547 $image = phutil_tag( ··· 554 550 'class' => 'phui-object-item-ficon', 555 551 ), 556 552 $this->fontIcon); 553 + } 554 + 555 + if ($image && $this->href) { 556 + $image = phutil_tag( 557 + 'a', 558 + array( 559 + 'href' => $this->href, 560 + ), 561 + $image); 557 562 } 558 563 559 564 /* Build a fake table */
+4 -25
webroot/rsrc/css/phui/phui-object-item-list-view.css
··· 616 616 */ 617 617 618 618 .phui-object-item-ficon { 619 - width: 26px; 619 + width: 48px; 620 620 height: 26px; 621 - margin: 11px 9px 7px 12px; 621 + margin-top: 12px; 622 622 position: absolute; 623 - } 624 - 625 - .device-desktop .phui-object-list-states .phui-object-item { 626 - margin: 0; 623 + text-align: center; 624 + font-size: 24px; 627 625 } 628 626 629 627 .phui-object-item-with-ficon .phui-object-item-content-box { ··· 637 635 .phui-object-list-states .aphront-error-view { 638 636 margin: 0; 639 637 border: none; 640 - } 641 - 642 - .phui-object-box .phui-object-list-states li:last-child 643 - .phui-object-item-frame { 644 - border: none; 645 - padding-bottom: 0; 646 - } 647 - 648 - .phui-object-list-states .phui-object-item-frame { 649 - border: none; 650 - border-bottom: 1px solid {$thinblueborder}; 651 - } 652 - 653 - .phui-object-list-states .phui-object-item { 654 - border: none; 655 - } 656 - 657 - .phui-object-list-states .phui-object-item-frame { 658 - min-height: 44px; 659 638 } 660 639 661 640 /* - Dashboards ------------------------------------------------------------ */