1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-10 00:42:41 +01:00

Update Phriction Edit page to new UI

Summary: Updates document edit page

Test Plan: review

Reviewers: epriestley, amckinley

Reviewed By: epriestley

Spies: Korvin

Differential Revision: https://secure.phabricator.com/D18546
This commit is contained in:
Chad Little 2017-09-06 11:31:07 -07:00
parent faca1deea5
commit 2abbb59cb4

View file

@ -195,19 +195,15 @@ final class PhrictionEditController
}
if ($document->getID()) {
$panel_header = pht('Edit Document: %s', $content->getTitle());
$page_title = pht('Edit Document');
$header_icon = 'fa-pencil';
$page_title = pht('Edit Document: %s', $content->getTitle());
if ($overwrite) {
$submit_button = pht('Overwrite Changes');
} else {
$submit_button = pht('Save Changes');
}
} else {
$panel_header = pht('Create New Phriction Document');
$submit_button = pht('Create Document');
$page_title = pht('Create Document');
$header_icon = 'fa-plus-square';
}
$uri = $document->getSlug();
@ -289,9 +285,9 @@ final class PhrictionEditController
->setValue($submit_button));
$form_box = id(new PHUIObjectBoxView())
->setHeaderText(pht('Document'))
->setHeaderText($page_title)
->setValidationException($validation_exception)
->setBackground(PHUIObjectBoxView::BLUE_PROPERTY)
->setBackground(PHUIObjectBoxView::WHITE_CONFIG)
->setForm($form);
$preview = id(new PHUIRemarkupPreviewPanel())
@ -311,12 +307,7 @@ final class PhrictionEditController
}
$crumbs->setBorder(true);
$header = id(new PHUIHeaderView())
->setHeader($panel_header)
->setHeaderIcon($header_icon);
$view = id(new PHUITwoColumnView())
->setHeader($header)
->setFooter(array(
$draft_note,
$form_box,