mirror of
https://we.phorge.it/source/phorge.git
synced 2025-03-28 20:18:13 +01:00
Update stock Homepage to look like Dashboards
Summary: Swaps out AphrontPanels for ObjectBoxes. I'd like to start reducing the floating object lists around the site for consistency. Also, these should provide more items above the fold. Test Plan: Test on my local homepage. Built a fake welcome.html too, though I think that's deprecated. {F277020} {F277021} Reviewers: btrahan, epriestley Reviewed By: epriestley Subscribers: Korvin, epriestley Differential Revision: https://secure.phabricator.com/D11529
This commit is contained in:
parent
5c71da8cdb
commit
48f15fb960
5 changed files with 53 additions and 38 deletions
|
@ -7,7 +7,7 @@
|
|||
*/
|
||||
return array(
|
||||
'names' => array(
|
||||
'core.pkg.css' => '3d6955ad',
|
||||
'core.pkg.css' => '04a24e98',
|
||||
'core.pkg.js' => '7a54aa14',
|
||||
'darkconsole.pkg.js' => '8ab24e01',
|
||||
'differential.pkg.css' => '8af45893',
|
||||
|
@ -26,7 +26,7 @@ return array(
|
|||
'rsrc/css/aphront/multi-column.css' => '41a848c0',
|
||||
'rsrc/css/aphront/notification.css' => '9c279160',
|
||||
'rsrc/css/aphront/pager-view.css' => '2e3539af',
|
||||
'rsrc/css/aphront/panel-view.css' => '5846dfa2',
|
||||
'rsrc/css/aphront/panel-view.css' => 'a5fee23a',
|
||||
'rsrc/css/aphront/phabricator-nav-view.css' => '7aeaf435',
|
||||
'rsrc/css/aphront/table-view.css' => 'b22b7216',
|
||||
'rsrc/css/aphront/tokenizer.css' => '82ce2142',
|
||||
|
@ -71,6 +71,7 @@ return array(
|
|||
'rsrc/css/application/harbormaster/harbormaster.css' => '49d64eb4',
|
||||
'rsrc/css/application/herald/herald-test.css' => '778b008e',
|
||||
'rsrc/css/application/herald/herald.css' => '826075fa',
|
||||
'rsrc/css/application/home/home.css' => 'e34bf140',
|
||||
'rsrc/css/application/maniphest/batch-editor.css' => '8f380ebc',
|
||||
'rsrc/css/application/maniphest/report.css' => '6fc16517',
|
||||
'rsrc/css/application/maniphest/task-edit.css' => '8e23031b',
|
||||
|
@ -136,7 +137,7 @@ return array(
|
|||
'rsrc/css/phui/phui-info-panel.css' => '27ea50a1',
|
||||
'rsrc/css/phui/phui-list.css' => '53deb25c',
|
||||
'rsrc/css/phui/phui-object-box.css' => '0d47b3c8',
|
||||
'rsrc/css/phui/phui-object-item-list-view.css' => '10297907',
|
||||
'rsrc/css/phui/phui-object-item-list-view.css' => '832c58fe',
|
||||
'rsrc/css/phui/phui-pinboard-view.css' => '3dd4a269',
|
||||
'rsrc/css/phui/phui-property-list-view.css' => '51480060',
|
||||
'rsrc/css/phui/phui-remarkup-preview.css' => '19ad512b',
|
||||
|
@ -497,7 +498,7 @@ return array(
|
|||
'aphront-list-filter-view-css' => '2ae43867',
|
||||
'aphront-multi-column-view-css' => '41a848c0',
|
||||
'aphront-pager-view-css' => '2e3539af',
|
||||
'aphront-panel-view-css' => '5846dfa2',
|
||||
'aphront-panel-view-css' => 'a5fee23a',
|
||||
'aphront-table-view-css' => 'b22b7216',
|
||||
'aphront-tokenizer-control-css' => '82ce2142',
|
||||
'aphront-tooltip-css' => '4099b97e',
|
||||
|
@ -531,6 +532,7 @@ return array(
|
|||
'herald-css' => '826075fa',
|
||||
'herald-rule-editor' => '335fd41f',
|
||||
'herald-test-css' => '778b008e',
|
||||
'homepage-panel-css' => 'e34bf140',
|
||||
'inline-comment-summary-css' => '8cfd34e8',
|
||||
'javelin-aphlict' => '2be71d56',
|
||||
'javelin-behavior' => '61cbc29a',
|
||||
|
@ -781,7 +783,7 @@ return array(
|
|||
'phui-info-panel-css' => '27ea50a1',
|
||||
'phui-list-view-css' => '53deb25c',
|
||||
'phui-object-box-css' => '0d47b3c8',
|
||||
'phui-object-item-list-view-css' => '10297907',
|
||||
'phui-object-item-list-view-css' => '832c58fe',
|
||||
'phui-pinboard-view-css' => '3dd4a269',
|
||||
'phui-property-list-view-css' => '51480060',
|
||||
'phui-remarkup-preview-css' => '19ad512b',
|
||||
|
|
|
@ -105,16 +105,23 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
$revision_panel = null;
|
||||
}
|
||||
|
||||
return array(
|
||||
$welcome_panel,
|
||||
$unbreak_panel,
|
||||
$triage_panel,
|
||||
$revision_panel,
|
||||
$tasks_panel,
|
||||
$audit_panel,
|
||||
$commit_panel,
|
||||
$this->minipanels,
|
||||
);
|
||||
require_celerity_resource('homepage-panel-css');
|
||||
$home = phutil_tag(
|
||||
'div',
|
||||
array(
|
||||
'class' => 'homepage-panel',
|
||||
),
|
||||
array(
|
||||
$welcome_panel,
|
||||
$unbreak_panel,
|
||||
$triage_panel,
|
||||
$revision_panel,
|
||||
$tasks_panel,
|
||||
$audit_panel,
|
||||
$commit_panel,
|
||||
$this->minipanels,
|
||||
));
|
||||
return $home;
|
||||
}
|
||||
|
||||
private function buildUnbreakNowPanel() {
|
||||
|
@ -146,10 +153,9 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
implode(',', ManiphestTaskStatus::getOpenStatusConstants()),
|
||||
$unbreak_now);
|
||||
$title = pht('Unbreak Now!');
|
||||
$panel = new AphrontPanelView();
|
||||
$panel = new PHUIObjectBoxView();
|
||||
$panel->setHeader($this->renderSectionHeader($title, $href));
|
||||
$panel->appendChild($this->buildTaskListView($tasks));
|
||||
$panel->setNoBackground();
|
||||
|
||||
return $panel;
|
||||
}
|
||||
|
@ -195,10 +201,9 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
implode(',', ManiphestTaskStatus::getOpenStatusConstants()),
|
||||
$needs_triage,
|
||||
$user->getPHID());
|
||||
$panel = new AphrontPanelView();
|
||||
$panel = new PHUIObjectBoxView();
|
||||
$panel->setHeader($this->renderSectionHeader($title, $href));
|
||||
$panel->appendChild($this->buildTaskListView($tasks));
|
||||
$panel->setNoBackground();
|
||||
|
||||
return $panel;
|
||||
}
|
||||
|
@ -229,7 +234,7 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
|
||||
$title = pht('Revisions Waiting on You');
|
||||
$href = '/differential';
|
||||
$panel = new AphrontPanelView();
|
||||
$panel = new PHUIObjectBoxView();
|
||||
$panel->setHeader($this->renderSectionHeader($title, $href));
|
||||
|
||||
$revision_view = id(new DifferentialRevisionListView())
|
||||
|
@ -247,17 +252,16 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
$list_view->setFlush(true);
|
||||
|
||||
$panel->appendChild($list_view);
|
||||
$panel->setNoBackground();
|
||||
|
||||
return $panel;
|
||||
}
|
||||
|
||||
private function buildWelcomePanel() {
|
||||
$panel = new AphrontPanelView();
|
||||
$panel = new PHUIObjectBoxView();
|
||||
$panel->setHeaderText(pht('Welcome'));
|
||||
$panel->appendChild(
|
||||
phutil_safe_html(
|
||||
PhabricatorEnv::getEnvConfig('welcome.html')));
|
||||
$panel->setNoBackground();
|
||||
|
||||
return $panel;
|
||||
}
|
||||
|
@ -285,10 +289,9 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
|
||||
$title = pht('Assigned Tasks');
|
||||
$href = '/maniphest';
|
||||
$panel = new AphrontPanelView();
|
||||
$panel = new PHUIObjectBoxView();
|
||||
$panel->setHeader($this->renderSectionHeader($title, $href));
|
||||
$panel->appendChild($this->buildTaskListView($tasks));
|
||||
$panel->setNoBackground();
|
||||
|
||||
return $panel;
|
||||
}
|
||||
|
@ -312,12 +315,14 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
}
|
||||
|
||||
private function renderSectionHeader($title, $href) {
|
||||
$header = phutil_tag(
|
||||
$title = phutil_tag(
|
||||
'a',
|
||||
array(
|
||||
'href' => $href,
|
||||
),
|
||||
$title);
|
||||
$header = id(new PHUIHeaderView())
|
||||
->setHeader($title);
|
||||
return $header;
|
||||
}
|
||||
|
||||
|
@ -368,10 +373,9 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
|
||||
$title = pht('Audits');
|
||||
$href = '/audit/';
|
||||
$panel = new AphrontPanelView();
|
||||
$panel = new PHUIObjectBoxView();
|
||||
$panel->setHeader($this->renderSectionHeader($title, $href));
|
||||
$panel->appendChild($view);
|
||||
$panel->setNoBackground();
|
||||
|
||||
return $panel;
|
||||
}
|
||||
|
@ -408,10 +412,9 @@ final class PhabricatorHomeMainController extends PhabricatorHomeController {
|
|||
|
||||
$title = pht('Problem Commits');
|
||||
$href = '/audit/';
|
||||
$panel = new AphrontPanelView();
|
||||
$panel = new PHUIObjectBoxView();
|
||||
$panel->setHeader($this->renderSectionHeader($title, $href));
|
||||
$panel->appendChild($view);
|
||||
$panel->setNoBackground();
|
||||
|
||||
return $panel;
|
||||
}
|
||||
|
|
|
@ -122,7 +122,7 @@
|
|||
.aphront-mini-panel-view {
|
||||
background: #fff;
|
||||
padding: 10px;
|
||||
margin: 4px 16px;
|
||||
margin: 16px 16px 0 16px;
|
||||
border: 1px solid {$lightgreyborder};
|
||||
border-bottom: 1px solid {$greyborder};
|
||||
}
|
||||
|
|
9
webroot/rsrc/css/application/home/home.css
Normal file
9
webroot/rsrc/css/application/home/home.css
Normal file
|
@ -0,0 +1,9 @@
|
|||
/**
|
||||
* @provides homepage-panel-css
|
||||
*/
|
||||
|
||||
.homepage-panel h1.phui-header-view {
|
||||
font-size: 14px;
|
||||
padding-top: 4px;
|
||||
padding-bottom: 4px;
|
||||
}
|
|
@ -19,16 +19,15 @@ ul.phui-object-item-list-view {
|
|||
padding: 0;
|
||||
}
|
||||
|
||||
.phui-object-box .phui-object-item-list-view.phui-object-list-flush {
|
||||
padding: 8px 8px 4px 8px;
|
||||
background-color: #E5E8EE;
|
||||
}
|
||||
|
||||
.device-phone .phui-object-box
|
||||
.phui-object-item-list-view.phui-object-list-flush {
|
||||
padding: 4px;
|
||||
}
|
||||
|
||||
.phui-object-item-list-view.phui-object-list-flush .phui-object-item {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.phui-object-item-list-view .aphront-error-view {
|
||||
margin: 4px 0 8px 0;
|
||||
color: {$greytext};
|
||||
|
@ -647,14 +646,16 @@ ul.phui-object-item-icons {
|
|||
margin-bottom: -1px;
|
||||
}
|
||||
|
||||
.dashboard-panel .phui-object-item-list-view .phui-object-item {
|
||||
.dashboard-panel .phui-object-item-list-view .phui-object-item,
|
||||
.phui-object-box .phui-object-item-list-view.phui-object-list-flush {
|
||||
margin: 0;
|
||||
background-image: none;
|
||||
background-color: #fff;
|
||||
border-left-width: 4px;
|
||||
}
|
||||
|
||||
.dashboard-panel .phui-object-item-frame {
|
||||
.dashboard-panel .phui-object-item-frame,
|
||||
.phui-object-box .phui-object-list-flush .phui-object-item-frame {
|
||||
border: none;
|
||||
border-bottom: 1px solid {$thinblueborder};
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue