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

Remove AphrontPanelView from Diffusion

Summary: Removes remaining AphrontPanelView calls in Diffusion for UI Consistency.

Test Plan: Tested each page except lint details, which I couldn't quite find a path to. Everything looks right.

Reviewers: epriestley, btrahan

Reviewed By: btrahan

Subscribers: Korvin, epriestley

Maniphest Tasks: T7427

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

+40 -37
+4 -4
src/applications/diffusion/controller/DiffusionBranchTableController.php
··· 45 45 ->setCommits($commits) 46 46 ->setDiffusionRequest($drequest); 47 47 48 - $panel = id(new AphrontPanelView()) 49 - ->setNoBackground(true) 50 - ->appendChild($view) 51 - ->appendChild($pager); 48 + $panel = id(new PHUIObjectBoxView()) 49 + ->setHeaderText(pht('Branches')) 50 + ->appendChild($view); 52 51 53 52 $content = $panel; 54 53 } ··· 62 61 array( 63 62 $crumbs, 64 63 $content, 64 + $pager, 65 65 ), 66 66 array( 67 67 'title' => array(
+2 -2
src/applications/diffusion/controller/DiffusionBrowseDirectoryController.php
··· 57 57 $browse_table->setPaths($results->getPaths()); 58 58 $browse_table->setUser($request->getUser()); 59 59 60 - $browse_panel = new AphrontPanelView(); 60 + $browse_panel = new PHUIObjectBoxView(); 61 + $browse_panel->setHeaderText($drequest->getPath(), '/'); 61 62 $browse_panel->appendChild($browse_table); 62 - $browse_panel->setNoBackground(); 63 63 64 64 $content[] = $browse_panel; 65 65 }
+10 -7
src/applications/diffusion/controller/DiffusionCommitController.php
··· 899 899 $caption = null; 900 900 if (count($merges) > $limit) { 901 901 $merges = array_slice($merges, 0, $limit); 902 - $caption = 903 - "This commit merges more than {$limit} changes. Only the first ". 904 - "{$limit} are shown."; 902 + $caption = new PHUIInfoView(); 903 + $caption->setSeverity(PHUIInfoView::SEVERITY_NOTICE); 904 + $caption->appendChild( 905 + pht('This commit merges more than %d changes. Only the first '. 906 + '%d are shown.', $limit)); 905 907 } 906 908 907 909 $history_table = new DiffusionHistoryTableView(); ··· 914 916 $handles = $this->loadViewerHandles($phids); 915 917 $history_table->setHandles($handles); 916 918 917 - $panel = new AphrontPanelView(); 918 - $panel->setHeader(pht('Merged Changes')); 919 - $panel->setCaption($caption); 919 + $panel = new PHUIObjectBoxView(); 920 + $panel->setHeaderText(pht('Merged Changes')); 920 921 $panel->appendChild($history_table); 921 - $panel->setNoBackground(); 922 + if ($caption) { 923 + $panel->setErrorView($caption); 924 + } 922 925 923 926 return $panel; 924 927 }
+8 -4
src/applications/diffusion/controller/DiffusionExternalController.php
··· 124 124 'wide', 125 125 )); 126 126 127 - $content = new AphrontPanelView(); 128 - $content->setHeader(pht('Multiple Matching Commits')); 129 - $content->setCaption( 130 - pht('This external reference matches multiple known commits.')); 127 + $caption = id(new PHUIInfoView()) 128 + ->setSeverity(PHUIInfoView::SEVERITY_NOTICE) 129 + ->appendChild( 130 + pht('This external reference matches multiple known commits.')); 131 + 132 + $content = new PHUIObjectBoxView(); 133 + $content->setHeaderText(pht('Multiple Matching Commits')); 134 + $content->setErrorView($caption); 131 135 $content->appendChild($table); 132 136 } 133 137
+3 -3
src/applications/diffusion/controller/DiffusionHistoryController.php
··· 57 57 $history_table->setIsHead($offset == 0); 58 58 } 59 59 60 - $history_panel = new AphrontPanelView(); 60 + $history_panel = new PHUIObjectBoxView(); 61 + $history_panel->setHeaderText(pht('History')); 61 62 $history_panel->appendChild($history_table); 62 - $history_panel->appendChild($pager); 63 - $history_panel->setNoBackground(); 64 63 65 64 $content[] = $history_panel; 66 65 ··· 88 87 $crumbs, 89 88 $object_box, 90 89 $content, 90 + $pager, 91 91 ), 92 92 array( 93 93 'title' => array(
+2 -4
src/applications/diffusion/controller/DiffusionLintController.php
··· 104 104 105 105 $content = array(); 106 106 107 - $link = null; 108 107 if (!$this->diffusionRequest) { 109 108 $form = id(new AphrontFormView()) 110 109 ->setUser($user) ··· 122 121 $content[] = id(new AphrontListFilterView())->appendChild($form); 123 122 } 124 123 125 - $content[] = id(new AphrontPanelView()) 126 - ->setNoBackground(true) 127 - ->setCaption($link) 124 + $content[] = id(new PHUIObjectBoxView()) 125 + ->setHeaderText(pht('Lint')) 128 126 ->appendChild($table); 129 127 130 128 $title = array('Lint');
+4 -4
src/applications/diffusion/controller/DiffusionLintDetailsController.php
··· 72 72 ->setHasMorePages(count($messages) >= $limit) 73 73 ->setURI($request->getRequestURI(), 'offset'); 74 74 75 - $content[] = id(new AphrontPanelView()) 76 - ->setNoBackground(true) 77 - ->appendChild($table) 78 - ->appendChild($pager); 75 + $content[] = id(new PHUIObjectBoxView()) 76 + ->setHeaderText(pht('Lint Details')) 77 + ->appendChild($table); 79 78 80 79 $crumbs = $this->buildCrumbs( 81 80 array( ··· 88 87 array( 89 88 $crumbs, 90 89 $content, 90 + $pager, 91 91 ), 92 92 array( 93 93 'title' =>
+3 -5
src/applications/diffusion/controller/DiffusionSymbolController.php
··· 137 137 $table->setNoDataString( 138 138 pht('No matching symbol could be found in any indexed project.')); 139 139 140 - $panel = new AphrontPanelView(); 141 - $panel->setHeader(pht('Similar Symbols')); 140 + $panel = new PHUIObjectBoxView(); 141 + $panel->setHeaderText(pht('Similar Symbols')); 142 142 $panel->appendChild($table); 143 143 144 144 return $this->buildApplicationPage( 145 - array( 146 - $panel, 147 - ), 145 + $panel, 148 146 array( 149 147 'title' => pht('Find Symbol'), 150 148 ));
+4 -4
src/applications/diffusion/controller/DiffusionTagListController.php
··· 66 66 $handles = $this->loadViewerHandles($phids); 67 67 $view->setHandles($handles); 68 68 69 - $panel = id(new AphrontPanelView()) 70 - ->setNoBackground(true) 71 - ->appendChild($view) 72 - ->appendChild($pager); 69 + $panel = id(new PHUIObjectBoxView()) 70 + ->setHeaderText(pht('Tags')) 71 + ->appendChild($view); 73 72 74 73 $content = $panel; 75 74 } ··· 84 83 array( 85 84 $crumbs, 86 85 $content, 86 + $pager, 87 87 ), 88 88 array( 89 89 'title' => array(