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

Policy, Status in PHUIHeaderView

Summary: The adds the ability to set 'properties' such as state, privacy, due date to the header of objects.

Test Plan: Implemented in Paste, Pholio. Tested various states.

Reviewers: epriestley, btrahan

Reviewed By: epriestley

CC: Korvin, aran

Differential Revision: https://secure.phabricator.com/D7016
This commit is contained in:
Chad Little 2013-09-17 09:12:37 -07:00
parent 01eedd6e6a
commit e8bb24fd60
114 changed files with 497 additions and 324 deletions

View file

@ -151,6 +151,16 @@
"rule" : ".status-minus-white", "rule" : ".status-minus-white",
"hash" : "c5a3771452dda603fbaee87371044f5a" "hash" : "c5a3771452dda603fbaee87371044f5a"
}, },
"status-oh-closed" : {
"name" : "status-oh-closed",
"rule" : ".status-oh-closed",
"hash" : "cbc6a0959ebad3e88cc3ac67743a7f3a"
},
"status-oh-open" : {
"name" : "status-oh-open",
"rule" : ".status-oh-open",
"hash" : "e86f83bc40e77664c91c834b27816576"
},
"status-open-blue" : { "status-open-blue" : {
"name" : "status-open-blue", "name" : "status-open-blue",
"rule" : ".status-open-blue", "rule" : ".status-open-blue",
@ -176,6 +186,41 @@
"rule" : ".status-open-white", "rule" : ".status-open-white",
"hash" : "169dc0e8f36444ea30163181f9c88dc2" "hash" : "169dc0e8f36444ea30163181f9c88dc2"
}, },
"status-policy-admin" : {
"name" : "status-policy-admin",
"rule" : ".status-policy-admin",
"hash" : "1df35b15bd20880a5d20c0a2da446472"
},
"status-policy-all" : {
"name" : "status-policy-all",
"rule" : ".status-policy-all",
"hash" : "ef0c0594968b04ed90ca8dc629a39e54"
},
"status-policy-custom" : {
"name" : "status-policy-custom",
"rule" : ".status-policy-custom",
"hash" : "a432adf61806705c54ad7e110e063829"
},
"status-policy-noone" : {
"name" : "status-policy-noone",
"rule" : ".status-policy-noone",
"hash" : "23b4a85b15930c46fa409e95d26be2c4"
},
"status-policy-project" : {
"name" : "status-policy-project",
"rule" : ".status-policy-project",
"hash" : "bbc9e90f3353a357c5a39e703825504e"
},
"status-policy-public" : {
"name" : "status-policy-public",
"rule" : ".status-policy-public",
"hash" : "4e6e9763dbb87dca73847e64ef0b87e6"
},
"status-policy-unknown" : {
"name" : "status-policy-unknown",
"rule" : ".status-policy-unknown",
"hash" : "f32c8a68221f735e443cb8b18b41ee0e"
},
"status-question-blue" : { "status-question-blue" : {
"name" : "status-question-blue", "name" : "status-question-blue",
"rule" : ".status-question-blue", "rule" : ".status-question-blue",

Binary file not shown.

After

Width:  |  Height:  |  Size: 291 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 231 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 296 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 340 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 266 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 327 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 193 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 323 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 308 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 706 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 540 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 346 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 497 B

View file

@ -96,7 +96,7 @@ $package_spec = array(
'phabricator-notification-css', 'phabricator-notification-css',
'phabricator-notification-menu-css', 'phabricator-notification-menu-css',
'lightbox-attachment-css', 'lightbox-attachment-css',
'phabricator-header-view-css', 'phui-header-view-css',
'phabricator-filetree-view-css', 'phabricator-filetree-view-css',
'phabricator-nav-view-css', 'phabricator-nav-view-css',
'phabricator-side-menu-view-css', 'phabricator-side-menu-view-css',

View file

@ -702,15 +702,15 @@ celerity_register_resource_map(array(
), ),
'/rsrc/image/sprite-status-X2.png' => '/rsrc/image/sprite-status-X2.png' =>
array( array(
'hash' => '3c57299b04fc21bee8a20d2d019bf6b6', 'hash' => 'b26f204c1b5ff01e3facbf78ccdc358b',
'uri' => '/res/3c57299b/rsrc/image/sprite-status-X2.png', 'uri' => '/res/b26f204c/rsrc/image/sprite-status-X2.png',
'disk' => '/rsrc/image/sprite-status-X2.png', 'disk' => '/rsrc/image/sprite-status-X2.png',
'type' => 'png', 'type' => 'png',
), ),
'/rsrc/image/sprite-status.png' => '/rsrc/image/sprite-status.png' =>
array( array(
'hash' => 'b76029c6bac69fd5bd9ab82d254f2ef1', 'hash' => 'c1f9c28f3ab24a0f2d758331bb0f8a09',
'uri' => '/res/b76029c6/rsrc/image/sprite-status.png', 'uri' => '/res/c1f9c28f/rsrc/image/sprite-status.png',
'disk' => '/rsrc/image/sprite-status.png', 'disk' => '/rsrc/image/sprite-status.png',
'type' => 'png', 'type' => 'png',
), ),
@ -1149,7 +1149,7 @@ celerity_register_resource_map(array(
), ),
'diviner-shared-css' => 'diviner-shared-css' =>
array( array(
'uri' => '/res/ef49b30b/rsrc/css/diviner/diviner-shared.css', 'uri' => '/res/cba9c99e/rsrc/css/diviner/diviner-shared.css',
'type' => 'css', 'type' => 'css',
'requires' => 'requires' =>
array( array(
@ -3014,7 +3014,7 @@ celerity_register_resource_map(array(
), ),
'phabricator-action-list-view-css' => 'phabricator-action-list-view-css' =>
array( array(
'uri' => '/res/5478ce6c/rsrc/css/layout/phabricator-action-list-view.css', 'uri' => '/res/c6219563/rsrc/css/layout/phabricator-action-list-view.css',
'type' => 'css', 'type' => 'css',
'requires' => 'requires' =>
array( array(
@ -3080,7 +3080,7 @@ celerity_register_resource_map(array(
), ),
'phabricator-crumbs-view-css' => 'phabricator-crumbs-view-css' =>
array( array(
'uri' => '/res/ff818db7/rsrc/css/layout/phabricator-crumbs-view.css', 'uri' => '/res/4d722e16/rsrc/css/layout/phabricator-crumbs-view.css',
'type' => 'css', 'type' => 'css',
'requires' => 'requires' =>
array( array(
@ -3180,15 +3180,6 @@ celerity_register_resource_map(array(
), ),
'disk' => '/rsrc/css/application/flag/flag.css', 'disk' => '/rsrc/css/application/flag/flag.css',
), ),
'phabricator-header-view-css' =>
array(
'uri' => '/res/8b2bcc29/rsrc/css/layout/phabricator-header-view.css',
'type' => 'css',
'requires' =>
array(
),
'disk' => '/rsrc/css/layout/phabricator-header-view.css',
),
'phabricator-hovercard' => 'phabricator-hovercard' =>
array( array(
'uri' => '/res/7fb94260/rsrc/js/core/Hovercard.js', 'uri' => '/res/7fb94260/rsrc/js/core/Hovercard.js',
@ -3376,7 +3367,7 @@ celerity_register_resource_map(array(
), ),
'phabricator-property-list-view-css' => 'phabricator-property-list-view-css' =>
array( array(
'uri' => '/res/fdcbf4ab/rsrc/css/layout/phabricator-property-list-view.css', 'uri' => '/res/3a0ffc53/rsrc/css/layout/phabricator-property-list-view.css',
'type' => 'css', 'type' => 'css',
'requires' => 'requires' =>
array( array(
@ -3747,7 +3738,7 @@ celerity_register_resource_map(array(
), ),
'phui-document-view-css' => 'phui-document-view-css' =>
array( array(
'uri' => '/res/c95d4bdf/rsrc/css/phui/phui-document.css', 'uri' => '/res/7928af2d/rsrc/css/phui/phui-document.css',
'type' => 'css', 'type' => 'css',
'requires' => 'requires' =>
array( array(
@ -3781,9 +3772,18 @@ celerity_register_resource_map(array(
), ),
'disk' => '/rsrc/css/phui/phui-form-view.css', 'disk' => '/rsrc/css/phui/phui-form-view.css',
), ),
'phui-header-view-css' =>
array(
'uri' => '/res/7ce53631/rsrc/css/phui/phui-header-view.css',
'type' => 'css',
'requires' =>
array(
),
'disk' => '/rsrc/css/phui/phui-header-view.css',
),
'phui-icon-view-css' => 'phui-icon-view-css' =>
array( array(
'uri' => '/res/f78f4c64/rsrc/css/phui/phui-icon.css', 'uri' => '/res/28fb5ae5/rsrc/css/phui/phui-icon.css',
'type' => 'css', 'type' => 'css',
'requires' => 'requires' =>
array( array(
@ -4134,7 +4134,7 @@ celerity_register_resource_map(array(
), ),
'sprite-status-css' => 'sprite-status-css' =>
array( array(
'uri' => '/res/72b39c66/rsrc/css/sprite-status.css', 'uri' => '/res/d61bb845/rsrc/css/sprite-status.css',
'type' => 'css', 'type' => 'css',
'requires' => 'requires' =>
array( array(
@ -4171,7 +4171,7 @@ celerity_register_resource_map(array(
), array( ), array(
'packages' => 'packages' =>
array( array(
'606d1ed1' => '2c60f04c' =>
array( array(
'name' => 'core.pkg.css', 'name' => 'core.pkg.css',
'symbols' => 'symbols' =>
@ -4203,7 +4203,7 @@ celerity_register_resource_map(array(
24 => 'phabricator-notification-css', 24 => 'phabricator-notification-css',
25 => 'phabricator-notification-menu-css', 25 => 'phabricator-notification-menu-css',
26 => 'lightbox-attachment-css', 26 => 'lightbox-attachment-css',
27 => 'phabricator-header-view-css', 27 => 'phui-header-view-css',
28 => 'phabricator-filetree-view-css', 28 => 'phabricator-filetree-view-css',
29 => 'phabricator-nav-view-css', 29 => 'phabricator-nav-view-css',
30 => 'phabricator-side-menu-view-css', 30 => 'phabricator-side-menu-view-css',
@ -4218,7 +4218,7 @@ celerity_register_resource_map(array(
39 => 'phabricator-property-list-view-css', 39 => 'phabricator-property-list-view-css',
40 => 'phabricator-tag-view-css', 40 => 'phabricator-tag-view-css',
), ),
'uri' => '/res/pkg/606d1ed1/core.pkg.css', 'uri' => '/res/pkg/2c60f04c/core.pkg.css',
'type' => 'css', 'type' => 'css',
), ),
'8977e356' => '8977e356' =>
@ -4409,15 +4409,15 @@ celerity_register_resource_map(array(
), ),
'reverse' => 'reverse' =>
array( array(
'aphront-dialog-view-css' => '606d1ed1', 'aphront-dialog-view-css' => '2c60f04c',
'aphront-error-view-css' => '606d1ed1', 'aphront-error-view-css' => '2c60f04c',
'aphront-list-filter-view-css' => '606d1ed1', 'aphront-list-filter-view-css' => '2c60f04c',
'aphront-pager-view-css' => '606d1ed1', 'aphront-pager-view-css' => '2c60f04c',
'aphront-panel-view-css' => '606d1ed1', 'aphront-panel-view-css' => '2c60f04c',
'aphront-table-view-css' => '606d1ed1', 'aphront-table-view-css' => '2c60f04c',
'aphront-tokenizer-control-css' => '606d1ed1', 'aphront-tokenizer-control-css' => '2c60f04c',
'aphront-tooltip-css' => '606d1ed1', 'aphront-tooltip-css' => '2c60f04c',
'aphront-typeahead-control-css' => '606d1ed1', 'aphront-typeahead-control-css' => '2c60f04c',
'differential-changeset-view-css' => '44bfe40c', 'differential-changeset-view-css' => '44bfe40c',
'differential-core-view-css' => '44bfe40c', 'differential-core-view-css' => '44bfe40c',
'differential-inline-comment-editor' => '5e9e5c4e', 'differential-inline-comment-editor' => '5e9e5c4e',
@ -4431,7 +4431,7 @@ celerity_register_resource_map(array(
'differential-table-of-contents-css' => '44bfe40c', 'differential-table-of-contents-css' => '44bfe40c',
'diffusion-commit-view-css' => 'c8ce2d88', 'diffusion-commit-view-css' => 'c8ce2d88',
'diffusion-icons-css' => 'c8ce2d88', 'diffusion-icons-css' => 'c8ce2d88',
'global-drag-and-drop-css' => '606d1ed1', 'global-drag-and-drop-css' => '2c60f04c',
'inline-comment-summary-css' => '44bfe40c', 'inline-comment-summary-css' => '44bfe40c',
'javelin-aphlict' => '8977e356', 'javelin-aphlict' => '8977e356',
'javelin-behavior' => 'f32597c9', 'javelin-behavior' => 'f32597c9',
@ -4504,55 +4504,55 @@ celerity_register_resource_map(array(
'javelin-util' => 'f32597c9', 'javelin-util' => 'f32597c9',
'javelin-vector' => 'f32597c9', 'javelin-vector' => 'f32597c9',
'javelin-workflow' => 'f32597c9', 'javelin-workflow' => 'f32597c9',
'lightbox-attachment-css' => '606d1ed1', 'lightbox-attachment-css' => '2c60f04c',
'maniphest-task-summary-css' => '36d5d071', 'maniphest-task-summary-css' => '36d5d071',
'maniphest-transaction-detail-css' => '36d5d071', 'maniphest-transaction-detail-css' => '36d5d071',
'phabricator-action-list-view-css' => '606d1ed1', 'phabricator-action-list-view-css' => '2c60f04c',
'phabricator-application-launch-view-css' => '606d1ed1', 'phabricator-application-launch-view-css' => '2c60f04c',
'phabricator-busy' => '8977e356', 'phabricator-busy' => '8977e356',
'phabricator-content-source-view-css' => '44bfe40c', 'phabricator-content-source-view-css' => '44bfe40c',
'phabricator-core-css' => '606d1ed1', 'phabricator-core-css' => '2c60f04c',
'phabricator-crumbs-view-css' => '606d1ed1', 'phabricator-crumbs-view-css' => '2c60f04c',
'phabricator-drag-and-drop-file-upload' => '5e9e5c4e', 'phabricator-drag-and-drop-file-upload' => '5e9e5c4e',
'phabricator-dropdown-menu' => '8977e356', 'phabricator-dropdown-menu' => '8977e356',
'phabricator-file-upload' => '8977e356', 'phabricator-file-upload' => '8977e356',
'phabricator-filetree-view-css' => '606d1ed1', 'phabricator-filetree-view-css' => '2c60f04c',
'phabricator-flag-css' => '606d1ed1', 'phabricator-flag-css' => '2c60f04c',
'phabricator-header-view-css' => '606d1ed1',
'phabricator-hovercard' => '8977e356', 'phabricator-hovercard' => '8977e356',
'phabricator-jump-nav' => '606d1ed1', 'phabricator-jump-nav' => '2c60f04c',
'phabricator-keyboard-shortcut' => '8977e356', 'phabricator-keyboard-shortcut' => '8977e356',
'phabricator-keyboard-shortcut-manager' => '8977e356', 'phabricator-keyboard-shortcut-manager' => '8977e356',
'phabricator-main-menu-view' => '606d1ed1', 'phabricator-main-menu-view' => '2c60f04c',
'phabricator-menu-item' => '8977e356', 'phabricator-menu-item' => '8977e356',
'phabricator-nav-view-css' => '606d1ed1', 'phabricator-nav-view-css' => '2c60f04c',
'phabricator-notification' => '8977e356', 'phabricator-notification' => '8977e356',
'phabricator-notification-css' => '606d1ed1', 'phabricator-notification-css' => '2c60f04c',
'phabricator-notification-menu-css' => '606d1ed1', 'phabricator-notification-menu-css' => '2c60f04c',
'phabricator-object-selector-css' => '44bfe40c', 'phabricator-object-selector-css' => '44bfe40c',
'phabricator-phtize' => '8977e356', 'phabricator-phtize' => '8977e356',
'phabricator-prefab' => '8977e356', 'phabricator-prefab' => '8977e356',
'phabricator-project-tag-css' => '36d5d071', 'phabricator-project-tag-css' => '36d5d071',
'phabricator-property-list-view-css' => '606d1ed1', 'phabricator-property-list-view-css' => '2c60f04c',
'phabricator-remarkup-css' => '606d1ed1', 'phabricator-remarkup-css' => '2c60f04c',
'phabricator-shaped-request' => '5e9e5c4e', 'phabricator-shaped-request' => '5e9e5c4e',
'phabricator-side-menu-view-css' => '606d1ed1', 'phabricator-side-menu-view-css' => '2c60f04c',
'phabricator-standard-page-view' => '606d1ed1', 'phabricator-standard-page-view' => '2c60f04c',
'phabricator-tag-view-css' => '606d1ed1', 'phabricator-tag-view-css' => '2c60f04c',
'phabricator-textareautils' => '8977e356', 'phabricator-textareautils' => '8977e356',
'phabricator-tooltip' => '8977e356', 'phabricator-tooltip' => '8977e356',
'phabricator-transaction-view-css' => '606d1ed1', 'phabricator-transaction-view-css' => '2c60f04c',
'phabricator-zindex-css' => '606d1ed1', 'phabricator-zindex-css' => '2c60f04c',
'phui-button-css' => '606d1ed1', 'phui-button-css' => '2c60f04c',
'phui-form-css' => '606d1ed1', 'phui-form-css' => '2c60f04c',
'phui-form-view-css' => '606d1ed1', 'phui-form-view-css' => '2c60f04c',
'phui-icon-view-css' => '606d1ed1', 'phui-header-view-css' => '2c60f04c',
'phui-object-item-list-view-css' => '606d1ed1', 'phui-icon-view-css' => '2c60f04c',
'phui-spacing-css' => '606d1ed1', 'phui-object-item-list-view-css' => '2c60f04c',
'sprite-apps-large-css' => '606d1ed1', 'phui-spacing-css' => '2c60f04c',
'sprite-gradient-css' => '606d1ed1', 'sprite-apps-large-css' => '2c60f04c',
'sprite-icons-css' => '606d1ed1', 'sprite-gradient-css' => '2c60f04c',
'sprite-menu-css' => '606d1ed1', 'sprite-icons-css' => '2c60f04c',
'syntax-highlighting-css' => '606d1ed1', 'sprite-menu-css' => '2c60f04c',
'syntax-highlighting-css' => '2c60f04c',
), ),
)); ));

View file

@ -754,6 +754,7 @@ phutil_register_library_map(array(
'PHUIFormLayoutView' => 'view/form/PHUIFormLayoutView.php', 'PHUIFormLayoutView' => 'view/form/PHUIFormLayoutView.php',
'PHUIFormMultiSubmitControl' => 'view/form/control/PHUIFormMultiSubmitControl.php', 'PHUIFormMultiSubmitControl' => 'view/form/control/PHUIFormMultiSubmitControl.php',
'PHUIFormPageView' => 'view/form/PHUIFormPageView.php', 'PHUIFormPageView' => 'view/form/PHUIFormPageView.php',
'PHUIHeaderView' => 'view/phui/PHUIHeaderView.php',
'PHUIIconExample' => 'applications/uiexample/examples/PHUIIconExample.php', 'PHUIIconExample' => 'applications/uiexample/examples/PHUIIconExample.php',
'PHUIIconView' => 'view/phui/PHUIIconView.php', 'PHUIIconView' => 'view/phui/PHUIIconView.php',
'PHUIListExample' => 'applications/uiexample/examples/PHUIListExample.php', 'PHUIListExample' => 'applications/uiexample/examples/PHUIListExample.php',
@ -1229,7 +1230,6 @@ phutil_register_library_map(array(
'PhabricatorHandleQuery' => 'applications/phid/query/PhabricatorHandleQuery.php', 'PhabricatorHandleQuery' => 'applications/phid/query/PhabricatorHandleQuery.php',
'PhabricatorHash' => 'infrastructure/util/PhabricatorHash.php', 'PhabricatorHash' => 'infrastructure/util/PhabricatorHash.php',
'PhabricatorHashTestCase' => 'infrastructure/util/__tests__/PhabricatorHashTestCase.php', 'PhabricatorHashTestCase' => 'infrastructure/util/__tests__/PhabricatorHashTestCase.php',
'PhabricatorHeaderView' => 'view/layout/PhabricatorHeaderView.php',
'PhabricatorHelpController' => 'applications/help/controller/PhabricatorHelpController.php', 'PhabricatorHelpController' => 'applications/help/controller/PhabricatorHelpController.php',
'PhabricatorHelpKeyboardShortcutController' => 'applications/help/controller/PhabricatorHelpKeyboardShortcutController.php', 'PhabricatorHelpKeyboardShortcutController' => 'applications/help/controller/PhabricatorHelpKeyboardShortcutController.php',
'PhabricatorHovercardExample' => 'applications/uiexample/examples/PhabricatorHovercardExample.php', 'PhabricatorHovercardExample' => 'applications/uiexample/examples/PhabricatorHovercardExample.php',
@ -2839,6 +2839,7 @@ phutil_register_library_map(array(
'PHUIFormLayoutView' => 'AphrontView', 'PHUIFormLayoutView' => 'AphrontView',
'PHUIFormMultiSubmitControl' => 'AphrontFormControl', 'PHUIFormMultiSubmitControl' => 'AphrontFormControl',
'PHUIFormPageView' => 'AphrontView', 'PHUIFormPageView' => 'AphrontView',
'PHUIHeaderView' => 'AphrontView',
'PHUIIconExample' => 'PhabricatorUIExample', 'PHUIIconExample' => 'PhabricatorUIExample',
'PHUIIconView' => 'AphrontTagView', 'PHUIIconView' => 'AphrontTagView',
'PHUIListExample' => 'PhabricatorUIExample', 'PHUIListExample' => 'PhabricatorUIExample',
@ -3363,7 +3364,6 @@ phutil_register_library_map(array(
'PhabricatorGlobalUploadTargetView' => 'AphrontView', 'PhabricatorGlobalUploadTargetView' => 'AphrontView',
'PhabricatorHandleQuery' => 'PhabricatorCursorPagedPolicyAwareQuery', 'PhabricatorHandleQuery' => 'PhabricatorCursorPagedPolicyAwareQuery',
'PhabricatorHashTestCase' => 'PhabricatorTestCase', 'PhabricatorHashTestCase' => 'PhabricatorTestCase',
'PhabricatorHeaderView' => 'AphrontView',
'PhabricatorHelpController' => 'PhabricatorController', 'PhabricatorHelpController' => 'PhabricatorController',
'PhabricatorHelpKeyboardShortcutController' => 'PhabricatorHelpController', 'PhabricatorHelpKeyboardShortcutController' => 'PhabricatorHelpController',
'PhabricatorHovercardExample' => 'PhabricatorUIExample', 'PhabricatorHovercardExample' => 'PhabricatorUIExample',

View file

@ -30,7 +30,7 @@ final class PhabricatorCalendarViewStatusController
$nav->appendChild( $nav->appendChild(
array( array(
id(new PhabricatorHeaderView())->setHeader($page_title), id(new PHUIHeaderView())->setHeader($page_title),
$status_list, $status_list,
)); ));

View file

@ -385,10 +385,10 @@ final class PhabricatorConduitAPIController
$result_panel->setHeader('Method Result'); $result_panel->setHeader('Method Result');
$result_panel->appendChild($result_table); $result_panel->appendChild($result_table);
$param_head = id(new PhabricatorHeaderView()) $param_head = id(new PHUIHeaderView())
->setHeader(pht('Method Parameters')); ->setHeader(pht('Method Parameters'));
$result_head = id(new PhabricatorHeaderView()) $result_head = id(new PHUIHeaderView())
->setHeader(pht('Method Result')); ->setHeader(pht('Method Result'));
$method_uri = $this->getApplicationURI('method/'.$method.'/'); $method_uri = $this->getApplicationURI('method/'.$method.'/');

View file

@ -21,7 +21,7 @@ final class PhabricatorConfigGroupController
$title = pht('%s Configuration', $options->getName()); $title = pht('%s Configuration', $options->getName());
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$list = $this->buildOptionList($options->getOptions()); $list = $this->buildOptionList($options->getOptions());

View file

@ -17,7 +17,7 @@ final class PhabricatorConfigIssueListController
$list = $this->buildIssueList($issues); $list = $this->buildIssueList($issues);
$list->setNoDataString(pht("There are no open setup issues.")); $list->setNoDataString(pht("There are no open setup issues."));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Open Phabricator Setup Issues')); ->setHeader(pht('Open Phabricator Setup Issues'));
$nav->appendChild( $nav->appendChild(

View file

@ -15,7 +15,7 @@ final class PhabricatorConfigListController
$title = pht('Phabricator Configuration'); $title = pht('Phabricator Configuration');
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$nav->appendChild( $nav->appendChild(

View file

@ -41,7 +41,7 @@ final class PhabricatorCountdownViewController
id(new PhabricatorCrumbView()) id(new PhabricatorCrumbView())
->setName("C{$id}")); ->setName("C{$id}"));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$actions = $this->buildActionListView($countdown); $actions = $this->buildActionListView($countdown);

View file

@ -64,7 +64,7 @@ final class PhabricatorDaemonConsoleController
'n', 'n',
)); ));
$completed_header = id(new PhabricatorHeaderView()) $completed_header = id(new PHUIHeaderView())
->setHeader(pht('Recently Completed Tasks (Last 15m)')); ->setHeader(pht('Recently Completed Tasks (Last 15m)'));
$completed_panel = new AphrontPanelView(); $completed_panel = new AphrontPanelView();
@ -76,7 +76,7 @@ final class PhabricatorDaemonConsoleController
->withStatus(PhabricatorDaemonLogQuery::STATUS_ALIVE) ->withStatus(PhabricatorDaemonLogQuery::STATUS_ALIVE)
->execute(); ->execute();
$daemon_header = id(new PhabricatorHeaderView()) $daemon_header = id(new PHUIHeaderView())
->setHeader(pht('Active Daemons')); ->setHeader(pht('Active Daemons'));
$daemon_table = new PhabricatorDaemonLogListView(); $daemon_table = new PhabricatorDaemonLogListView();

View file

@ -30,7 +30,7 @@ final class PhabricatorDaemonLogViewController
id(new PhabricatorCrumbView()) id(new PhabricatorCrumbView())
->setName(pht('Daemon %s', $log->getID()))); ->setName(pht('Daemon %s', $log->getID())));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($log->getDaemon()); ->setHeader($log->getDaemon());
$tag = id(new PhabricatorTagView()) $tag = id(new PhabricatorTagView())

View file

@ -33,7 +33,7 @@ final class PhabricatorWorkerTaskDetailController
} else { } else {
$title = pht('Task %d', $task->getID()); $title = pht('Task %d', $task->getID());
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Task %d (%s)', ->setHeader(pht('Task %d (%s)',
$task->getID(), $task->getID(),
$task->getTaskClass())); $task->getTaskClass()));
@ -41,7 +41,7 @@ final class PhabricatorWorkerTaskDetailController
$actions = $this->buildActionListView($task); $actions = $this->buildActionListView($task);
$properties = $this->buildPropertyListView($task); $properties = $this->buildPropertyListView($task);
$retry_head = id(new PhabricatorHeaderView()) $retry_head = id(new PHUIHeaderView())
->setHeader(pht('Retries')); ->setHeader(pht('Retries'));
$retry_info = $this->buildRetryListView($task); $retry_info = $this->buildRetryListView($task);

View file

@ -114,7 +114,7 @@ final class DifferentialDiffViewController extends DifferentialController {
} }
} }
$property_head = id(new PhabricatorHeaderView()) $property_head = id(new PHUIHeaderView())
->setHeader(pht('Properties')); ->setHeader(pht('Properties'));
$property_view = new PhabricatorPropertyListView(); $property_view = new PhabricatorPropertyListView();

View file

@ -846,7 +846,7 @@ final class DifferentialRevisionViewController extends DifferentialController {
$view->setHandles($handles); $view->setHandles($handles);
return array( return array(
id(new PhabricatorHeaderView()) id(new PHUIHeaderView())
->setHeader(pht('Open Revisions Affecting These Files')), ->setHeader(pht('Open Revisions Affecting These Files')),
$view, $view,
); );

View file

@ -173,7 +173,7 @@ final class DifferentialAddCommentView extends AphrontView {
} }
} }
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($is_serious ? pht('Add Comment') : pht('Leap Into Action')); ->setHeader($is_serious ? pht('Add Comment') : pht('Leap Into Action'));
return hsprintf( return hsprintf(

View file

@ -195,7 +195,7 @@ final class DifferentialChangesetListView extends AphrontView {
} }
return array( return array(
id(new PhabricatorHeaderView()) id(new PHUIHeaderView())
->setHeader($this->getTitle()) ->setHeader($this->getTitle())
->render(), ->render(),
phutil_tag( phutil_tag(

View file

@ -232,7 +232,7 @@ final class DifferentialDiffTableOfContentsView extends AphrontView {
->setAnchorName('toc') ->setAnchorName('toc')
->setNavigationMarker(true) ->setNavigationMarker(true)
->render(), ->render(),
id(new PhabricatorHeaderView()) id(new PHUIHeaderView())
->setHeader(pht('Table of Contents')) ->setHeader(pht('Table of Contents'))
->render(), ->render(),
pht('Coverage (All)'), pht('Coverage (All)'),

View file

@ -128,7 +128,7 @@ final class DifferentialLocalCommitsView extends AphrontView {
$headers = phutil_tag('tr', array(), $headers); $headers = phutil_tag('tr', array(), $headers);
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Local Commits')) ->setHeader(pht('Local Commits'))
->render(); ->render();

View file

@ -119,7 +119,7 @@ final class DifferentialRevisionDetailView extends AphrontView {
} }
private function renderHeader(DifferentialRevision $revision) { private function renderHeader(DifferentialRevision $revision) {
$view = id(new PhabricatorHeaderView()) $view = id(new PHUIHeaderView())
->setHeader($revision->getTitle($revision)); ->setHeader($revision->getTitle($revision));
$view->addTag(self::renderTagForRevision($revision)); $view->addTag(self::renderTagForRevision($revision));

View file

@ -215,7 +215,7 @@ final class DifferentialRevisionUpdateHistoryView extends AphrontView {
'</table>'. '</table>'.
'</form>'. '</form>'.
'</div>', '</div>',
id(new PhabricatorHeaderView()) id(new PHUIHeaderView())
->setHeader(pht('Revision Update History')) ->setHeader(pht('Revision Update History'))
->render(), ->render(),
phutil_implode_html("\n", $rows), phutil_implode_html("\n", $rows),

View file

@ -95,7 +95,7 @@ final class DiffusionBrowseController extends DiffusionController {
$box->addPadding(PHUI::PADDING_LARGE); $box->addPadding(PHUI::PADDING_LARGE);
$box->addMargin(PHUI::MARGIN_LARGE); $box->addMargin(PHUI::MARGIN_LARGE);
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('README')); ->setHeader(pht('README'));
$content[] = array( $content[] = array(

View file

@ -85,7 +85,7 @@ final class DiffusionCommitController extends DiffusionController {
'diffusion.commitparentsquery', 'diffusion.commitparentsquery',
array('commit' => $drequest->getCommit())); array('commit' => $drequest->getCommit()));
$headsup_view = id(new PhabricatorHeaderView()) $headsup_view = id(new PHUIHeaderView())
->setHeader(nonempty($commit->getSummary(), pht('Commit Detail'))); ->setHeader(nonempty($commit->getSummary(), pht('Commit Detail')));
$headsup_actions = $this->renderHeadsupActionList($commit, $repository); $headsup_actions = $this->renderHeadsupActionList($commit, $repository);
@ -660,7 +660,7 @@ final class DiffusionCommitController extends DiffusionController {
id(new AphrontFormSubmitControl()) id(new AphrontFormSubmitControl())
->setValue($is_serious ? pht('Submit') : pht('Cook the Books'))); ->setValue($is_serious ? pht('Submit') : pht('Cook the Books')));
$header = new PhabricatorHeaderView(); $header = new PHUIHeaderView();
$header->setHeader( $header->setHeader(
$is_serious ? pht('Audit Commit') : pht('Creative Accounting')); $is_serious ? pht('Audit Commit') : pht('Creative Accounting'));

View file

@ -133,7 +133,7 @@ abstract class DiffusionController extends PhabricatorController {
$handles = $this->loadViewerHandles($phids); $handles = $this->loadViewerHandles($phids);
$view->setHandles($handles); $view->setHandles($handles);
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Pending Differential Revisions')); ->setHeader(pht('Pending Differential Revisions'));
return array( return array(

View file

@ -136,7 +136,7 @@ final class DiffusionRepositoryController extends DiffusionController {
private function buildPropertiesTable(PhabricatorRepository $repository) { private function buildPropertiesTable(PhabricatorRepository $repository) {
$user = $this->getRequest()->getUser(); $user = $this->getRequest()->getUser();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($repository->getName()); ->setHeader($repository->getName());
$view = id(new PhabricatorPropertyListView()) $view = id(new PhabricatorPropertyListView())

View file

@ -18,19 +18,19 @@ final class DiffusionRepositoryEditController extends DiffusionController {
$title = pht('Edit %s', $repository->getName()); $title = pht('Edit %s', $repository->getName());
$content[] = id(new PhabricatorHeaderView()) $content[] = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$content[] = $this->buildBasicActions($repository); $content[] = $this->buildBasicActions($repository);
$content[] = $this->buildBasicProperties($repository); $content[] = $this->buildBasicProperties($repository);
$content[] = id(new PhabricatorHeaderView()) $content[] = id(new PHUIHeaderView())
->setHeader(pht('Text Encoding')); ->setHeader(pht('Text Encoding'));
$content[] = $this->buildEncodingActions($repository); $content[] = $this->buildEncodingActions($repository);
$content[] = $this->buildEncodingProperties($repository); $content[] = $this->buildEncodingProperties($repository);
$content[] = id(new PhabricatorHeaderView()) $content[] = id(new PHUIHeaderView())
->setHeader(pht('Edit History')); ->setHeader(pht('Edit History'));
$xactions = id(new PhabricatorRepositoryTransactionQuery()) $xactions = id(new PhabricatorRepositoryTransactionQuery())

View file

@ -72,7 +72,7 @@ final class DivinerAtomController extends DivinerController {
id(new PhabricatorCrumbView()) id(new PhabricatorCrumbView())
->setName($atom_short_title)); ->setName($atom_short_title));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($this->renderFullSignature($symbol)) ->setHeader($this->renderFullSignature($symbol))
->addTag( ->addTag(
id(new PhabricatorTagView()) id(new PhabricatorTagView())
@ -153,7 +153,7 @@ final class DivinerAtomController extends DivinerController {
foreach ($tasks as $spec) { foreach ($tasks as $spec) {
$section->addContent( $section->addContent(
id(new PhabricatorHeaderView()) id(new PHUIHeaderView())
->setNoBackground(true) ->setNoBackground(true)
->setHeader($spec['title'])); ->setHeader($spec['title']));
@ -203,7 +203,7 @@ final class DivinerAtomController extends DivinerController {
foreach ($methods as $spec) { foreach ($methods as $spec) {
$matom = last($spec['atoms']); $matom = last($spec['atoms']);
$method_header = id(new PhabricatorHeaderView()) $method_header = id(new PHUIHeaderView())
->setNoBackground(true); ->setNoBackground(true);
$inherited = $spec['inherited']; $inherited = $spec['inherited'];

View file

@ -32,7 +32,7 @@ final class DivinerBookController extends DivinerController {
->setName($book->getShortTitle()) ->setName($book->getShortTitle())
->setHref('/book/'.$book->getName().'/')); ->setHref('/book/'.$book->getName().'/'));
$header = id(new PhabricatorHeaderView())->setHeader($book->getTitle()); $header = id(new PHUIHeaderView())->setHeader($book->getTitle());
$document = new PHUIDocumentView(); $document = new PHUIDocumentView();
$document->setHeader($header); $document->setHeader($header);

View file

@ -47,7 +47,7 @@ final class DivinerLegacyController extends DivinerController {
id(new PhabricatorCrumbView()) id(new PhabricatorCrumbView())
->setName(pht('Documentation'))); ->setName(pht('Documentation')));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Documentation')); ->setHeader(pht('Documentation'));
$document = new PHUIDocumentView(); $document = new PHUIDocumentView();

View file

@ -28,7 +28,7 @@ final class DivinerSectionView extends AphrontTagView {
public function getTagContent() { public function getTagContent() {
require_celerity_resource('diviner-shared-css'); require_celerity_resource('diviner-shared-css');
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setBleedHeader(true) ->setBleedHeader(true)
->setHeader($this->header); ->setHeader($this->header);

View file

@ -18,7 +18,7 @@ final class DrydockLeaseListController extends DrydockController {
$title = pht('Leases'); $title = pht('Leases');
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$lease_list = $this->buildLeaseListView($leases); $lease_list = $this->buildLeaseListView($leases);

View file

@ -21,7 +21,7 @@ final class DrydockLeaseViewController extends DrydockController {
$title = pht('Lease %d', $lease->getID()); $title = pht('Lease %d', $lease->getID());
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$actions = $this->buildActionListView($lease); $actions = $this->buildActionListView($lease);

View file

@ -29,7 +29,7 @@ final class DrydockLogController extends DrydockController {
$title = pht('Logs'); $title = pht('Logs');
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$table = $this->buildLogTableView($logs); $table = $this->buildLogTableView($logs);

View file

@ -8,7 +8,7 @@ final class DrydockResourceListController extends DrydockController {
$title = pht('Resources'); $title = pht('Resources');
$resource_header = id(new PhabricatorHeaderView()) $resource_header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$pager = new AphrontPagerView(); $pager = new AphrontPagerView();

View file

@ -19,7 +19,7 @@ final class DrydockResourceViewController extends DrydockController {
$title = 'Resource '.$resource->getID().' '.$resource->getName(); $title = 'Resource '.$resource->getID().' '.$resource->getName();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$actions = $this->buildActionListView($resource); $actions = $this->buildActionListView($resource);
@ -33,7 +33,7 @@ final class DrydockResourceViewController extends DrydockController {
->needResources(true) ->needResources(true)
->execute(); ->execute();
$lease_header = id(new PhabricatorHeaderView()) $lease_header = id(new PHUIHeaderView())
->setHeader(pht('Leases')); ->setHeader(pht('Leases'));
$lease_list = $this->buildLeaseListView($leases); $lease_list = $this->buildLeaseListView($leases);

View file

@ -28,7 +28,7 @@ final class PhabricatorFileInfoController extends PhabricatorFileController {
->execute(); ->execute();
$this->loadHandles(array($file->getAuthorPHID())); $this->loadHandles(array($file->getAuthorPHID()));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($file->getName()); ->setHeader($file->getName());
$ttl = $file->getTTL(); $ttl = $file->getTTL();
@ -88,7 +88,7 @@ final class PhabricatorFileInfoController extends PhabricatorFileController {
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business'); $is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
$add_comment_header = id(new PhabricatorHeaderView()) $add_comment_header = id(new PHUIHeaderView())
->setHeader( ->setHeader(
$is_serious $is_serious
? pht('Add Comment') ? pht('Add Comment')

View file

@ -21,7 +21,7 @@ final class HeraldRuleViewController extends HeraldController {
return new Aphront404Response(); return new Aphront404Response();
} }
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($rule->getName()); ->setHeader($rule->getName());
$actions = $this->buildActionView($rule); $actions = $this->buildActionView($rule);

View file

@ -119,7 +119,7 @@ final class LegalpadDocumentSignController extends LegalpadController {
$title = $document_body->getTitle(); $title = $document_body->getTitle();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$content = array( $content = array(

View file

@ -61,7 +61,7 @@ final class LegalpadDocumentViewController extends LegalpadController {
$title = $document_body->getTitle(); $title = $document_body->getTitle();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$actions = $this->buildActionView($document); $actions = $this->buildActionView($document);
@ -200,7 +200,7 @@ final class LegalpadDocumentViewController extends LegalpadController {
? pht('Add Comment') ? pht('Add Comment')
: pht('Debate Legislation'); : pht('Debate Legislation');
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$button_name = $is_serious $button_name = $is_serious

View file

@ -59,7 +59,7 @@ final class PhabricatorMacroViewController
->setTransactions($xactions) ->setTransactions($xactions)
->setMarkupEngine($engine); ->setMarkupEngine($engine);
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title_long); ->setHeader($title_long);
if ($macro->getIsDisabled()) { if ($macro->getIsDisabled()) {
@ -72,7 +72,7 @@ final class PhabricatorMacroViewController
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business'); $is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
$add_comment_header = id(new PhabricatorHeaderView()) $add_comment_header = id(new PHUIHeaderView())
->setHeader( ->setHeader(
$is_serious $is_serious
? pht('Add Comment') ? pht('Add Comment')

View file

@ -321,7 +321,7 @@ final class ManiphestTaskDetailController extends ManiphestController {
'tokenizers' => $tokenizer_map, 'tokenizers' => $tokenizer_map,
)); ));
$comment_header = id(new PhabricatorHeaderView()) $comment_header = id(new PHUIHeaderView())
->setHeader($is_serious ? pht('Add Comment') : pht('Weigh In')); ->setHeader($is_serious ? pht('Add Comment') : pht('Weigh In'));
$preview_panel = hsprintf( $preview_panel = hsprintf(
@ -372,7 +372,7 @@ final class ManiphestTaskDetailController extends ManiphestController {
} }
private function buildHeaderView(ManiphestTask $task) { private function buildHeaderView(ManiphestTask $task) {
$view = id(new PhabricatorHeaderView()) $view = id(new PHUIHeaderView())
->setHeader($task->getTitle()); ->setHeader($task->getTitle());
$view->addTag(ManiphestView::renderTagForTask($task)); $view->addTag(ManiphestView::renderTagForTask($task));

View file

@ -27,7 +27,7 @@ final class PhabricatorApplicationDetailViewController
->setName(pht('Applications')) ->setName(pht('Applications'))
->setHref($this->getApplicationURI())); ->setHref($this->getApplicationURI()));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$status_tag = id(new PhabricatorTagView()) $status_tag = id(new PhabricatorTagView())

View file

@ -104,7 +104,7 @@ final class PhabricatorPasteViewController extends PhabricatorPasteController {
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business'); $is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
$add_comment_header = id(new PhabricatorHeaderView()) $add_comment_header = id(new PHUIHeaderView())
->setHeader( ->setHeader(
$is_serious $is_serious
? pht('Add Comment') ? pht('Add Comment')
@ -142,8 +142,16 @@ final class PhabricatorPasteViewController extends PhabricatorPasteController {
} }
private function buildHeaderView(PhabricatorPaste $paste) { private function buildHeaderView(PhabricatorPaste $paste) {
return id(new PhabricatorHeaderView()) $descriptions = PhabricatorPolicyQuery::renderPolicyDescriptions(
->setHeader($paste->getTitle()); $this->getRequest()->getUser(),
$paste,
$icon = true);
$header = id(new PHUIHeaderView())
->setHeader($paste->getTitle())
->addProperty(PHUIHeaderView::PROPERTY_POLICY,
$descriptions[PhabricatorPolicyCapability::CAN_VIEW]);
return $header;
} }
private function buildActionView( private function buildActionView(
@ -217,10 +225,6 @@ final class PhabricatorPasteViewController extends PhabricatorPasteController {
$user, $user,
$paste); $paste);
$properties->addProperty(
pht('Visible To'),
$descriptions[PhabricatorPolicyCapability::CAN_VIEW]);
return $properties; return $properties;
} }

View file

@ -32,7 +32,7 @@ final class PhabricatorPeopleProfileController
$picture = $user->loadProfileImageURI(); $picture = $user->loadProfileImageURI();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($user->getUserName().' ('.$user->getRealName().')') ->setHeader($user->getUserName().' ('.$user->getRealName().')')
->setSubheader($profile->getTitle()) ->setSubheader($profile->getTitle())
->setImage($picture); ->setImage($picture);

View file

@ -33,7 +33,7 @@ final class PhameBlogViewController extends PhameController {
$nav = $this->renderSideNavFilterView(null); $nav = $this->renderSideNavFilterView(null);
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($blog->getName()); ->setHeader($blog->getName());
$handle_phids = array_merge( $handle_phids = array_merge(

View file

@ -43,7 +43,7 @@ final class PhamePostViewController extends PhameController {
$nav->appendChild($crumbs); $nav->appendChild($crumbs);
$nav->appendChild( $nav->appendChild(
id(new PhabricatorHeaderView()) id(new PHUIHeaderView())
->setHeader($post->getTitle())); ->setHeader($post->getTitle()));
if ($post->isDraft()) { if ($post->isDraft()) {

View file

@ -30,7 +30,7 @@ final class PhluxViewController extends PhluxController {
->setName($title) ->setName($title)
->setHref($request->getRequestURI())); ->setHref($request->getRequestURI()));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$actions = id(new PhabricatorActionListView()) $actions = id(new PhabricatorActionListView())

View file

@ -52,7 +52,7 @@ final class PholioImageHistoryController extends PholioController {
$latest_image->getName(), $latest_image->getName(),
$mock->getName()); $mock->getName());
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
require_celerity_resource('pholio-css'); require_celerity_resource('pholio-css');

View file

@ -67,8 +67,15 @@ final class PholioMockViewController extends PholioController {
$title = $mock->getName(); $title = $mock->getName();
$header = id(new PhabricatorHeaderView()) $descriptions = PhabricatorPolicyQuery::renderPolicyDescriptions(
->setHeader($title); $user,
$mock,
$icon = true);
$header = id(new PHUIHeaderView())
->setHeader($title)
->addProperty(PHUIHeaderView::PROPERTY_POLICY,
$descriptions[PhabricatorPolicyCapability::CAN_VIEW]);
$actions = $this->buildActionView($mock); $actions = $this->buildActionView($mock);
$properties = $this->buildPropertyView($mock, $engine); $properties = $this->buildPropertyView($mock, $engine);
@ -208,14 +215,6 @@ final class PholioMockViewController extends PholioController {
pht('Created'), pht('Created'),
phabricator_datetime($mock->getDateCreated(), $user)); phabricator_datetime($mock->getDateCreated(), $user));
$descriptions = PhabricatorPolicyQuery::renderPolicyDescriptions(
$user,
$mock);
$properties->addProperty(
pht('Visible To'),
$descriptions[PhabricatorPolicyCapability::CAN_VIEW]);
if ($this->getManiphestTaskPHIDs()) { if ($this->getManiphestTaskPHIDs()) {
$properties->addProperty( $properties->addProperty(
pht('Maniphest Tasks'), pht('Maniphest Tasks'),
@ -241,7 +240,7 @@ final class PholioMockViewController extends PholioController {
? pht('Add Comment') ? pht('Add Comment')
: pht('History Beckons'); : pht('History Beckons');
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$button_name = $is_serious $button_name = $is_serious

View file

@ -29,7 +29,7 @@ final class PhortuneAccountViewController extends PhortuneController {
->setName(pht('Account')) ->setName(pht('Account'))
->setHref($request->getRequestURI())); ->setHref($request->getRequestURI()));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$actions = id(new PhabricatorActionListView()) $actions = id(new PhabricatorActionListView())
@ -80,7 +80,7 @@ final class PhortuneAccountViewController extends PhortuneController {
$request = $this->getRequest(); $request = $this->getRequest();
$user = $request->getUser(); $user = $request->getUser();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Payment Methods')); ->setHeader(pht('Payment Methods'));
$id = $account->getID(); $id = $account->getID();
@ -141,7 +141,7 @@ final class PhortuneAccountViewController extends PhortuneController {
$request = $this->getRequest(); $request = $this->getRequest();
$user = $request->getUser(); $user = $request->getUser();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Purchase History')); ->setHeader(pht('Purchase History'));
return array( return array(
@ -154,7 +154,7 @@ final class PhortuneAccountViewController extends PhortuneController {
$request = $this->getRequest(); $request = $this->getRequest();
$user = $request->getUser(); $user = $request->getUser();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Account History')); ->setHeader(pht('Account History'));
$xactions = id(new PhortuneAccountTransactionQuery()) $xactions = id(new PhortuneAccountTransactionQuery())

View file

@ -155,7 +155,7 @@ final class PhortunePaymentMethodEditController
$request = $this->getRequest(); $request = $this->getRequest();
$title = pht('Add Payment Method'); $title = pht('Add Payment Method');
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$crumbs = $this->buildApplicationCrumbs(); $crumbs = $this->buildApplicationCrumbs();

View file

@ -144,7 +144,7 @@ final class PhortuneProductEditController extends PhabricatorController {
->setName($is_create ? pht('Create') : pht('Edit')) ->setName($is_create ? pht('Create') : pht('Edit'))
->setHref($request->getRequestURI())); ->setHref($request->getRequestURI()));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Edit Product')); ->setHeader(pht('Edit Product'));
return $this->buildApplicationPage( return $this->buildApplicationPage(

View file

@ -27,7 +27,7 @@ final class PhortuneProductListController extends PhabricatorController {
->setHref($this->getApplicationURI('product/edit/')) ->setHref($this->getApplicationURI('product/edit/'))
->setIcon('create')); ->setIcon('create'));
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Product List')); ->setHeader(pht('Product List'));
$product_list = id(new PHUIObjectItemListView()) $product_list = id(new PHUIObjectItemListView())

View file

@ -23,7 +23,7 @@ final class PhortuneProductViewController extends PhortuneController {
$title = pht('Product: %s', $product->getProductName()); $title = pht('Product: %s', $product->getProductName());
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($product->getProductName()); ->setHeader($product->getProductName());
$account = $this->loadActiveAccount($user); $account = $this->loadActiveAccount($user);

View file

@ -115,7 +115,7 @@ final class PhrictionDiffController
$title = "Version $l vs $r"; $title = "Version $l vs $r";
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($title); ->setHeader($title);
$crumbs->addCrumb( $crumbs->addCrumb(

View file

@ -159,7 +159,7 @@ final class PhrictionDocumentController
$crumbs->addCrumb($view); $crumbs->addCrumb($view);
} }
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($page_title); ->setHeader($page_title);
$page_content = id(new PHUIDocumentView()) $page_content = id(new PHUIDocumentView())

View file

@ -144,7 +144,7 @@ final class PhrictionHistoryController
->setHref( ->setHref(
PhrictionDocument::getSlugURI($document->getSlug(), 'history'))); PhrictionDocument::getSlugURI($document->getSlug(), 'history')));
$header = new PhabricatorHeaderView(); $header = new PHUIHeaderView();
$header->setHeader(pht('Document History for %s', $header->setHeader(pht('Document History for %s',
phutil_tag( phutil_tag(
'a', 'a',

View file

@ -6,6 +6,7 @@ final class PhabricatorPolicy {
private $name; private $name;
private $type; private $type;
private $href; private $href;
private $icon;
public static function newFromPolicyAndHandle( public static function newFromPolicyAndHandle(
$policy_identifier, $policy_identifier,
@ -86,6 +87,29 @@ final class PhabricatorPolicy {
return $this->href; return $this->href;
} }
public function getIcon() {
switch ($this->getType()) {
case PhabricatorPolicyType::TYPE_GLOBAL:
static $map = array(
PhabricatorPolicies::POLICY_PUBLIC => 'policy-public',
PhabricatorPolicies::POLICY_USER => 'policy-all',
PhabricatorPolicies::POLICY_ADMIN => 'policy-admin',
PhabricatorPolicies::POLICY_NOONE => 'policy-noone',
);
return idx($map, $this->getPHID(), 'policy-unknown');
break;
case PhabricatorPolicyType::TYPE_PROJECT:
return 'policy-project';
break;
case PhabricatorPolicyType::TYPE_MASKED:
return 'policy-custom';
break;
default:
return 'policy-unknown';
break;
}
}
public function getSortKey() { public function getSortKey() {
return sprintf( return sprintf(
'%02d%s', '%02d%s',
@ -117,16 +141,27 @@ final class PhabricatorPolicy {
} }
} }
public function renderDescription() { public function renderDescription($icon=false) {
$img = null;
if ($icon) {
$img = id(new PHUIIconView())
->setSpriteSheet(PHUIIconView::SPRITE_STATUS)
->setSpriteIcon($this->getIcon());
}
if ($this->getHref()) { if ($this->getHref()) {
$desc = phutil_tag( $desc = phutil_tag(
'a', 'a',
array( array(
'href' => $this->getHref(), 'href' => $this->getHref(),
'class' => 'policy-link',
), ),
$this->getName()); array(
$img,
$this->getName(),
));
} else { } else {
$desc = $this->getName(); $desc = array($img, $this->getName());
} }
switch ($this->getType()) { switch ($this->getType()) {
@ -140,6 +175,4 @@ final class PhabricatorPolicy {
return $desc; return $desc;
} }
} }
} }

View file

@ -17,7 +17,8 @@ final class PhabricatorPolicyQuery extends PhabricatorQuery {
public static function renderPolicyDescriptions( public static function renderPolicyDescriptions(
PhabricatorUser $viewer, PhabricatorUser $viewer,
PhabricatorPolicyInterface $object) { PhabricatorPolicyInterface $object,
$icon=false) {
$results = array(); $results = array();
$policies = null; $policies = null;
@ -31,7 +32,7 @@ final class PhabricatorPolicyQuery extends PhabricatorQuery {
} }
if (isset($global[$policy])) { if (isset($global[$policy])) {
$results[$capability] = $global[$policy]->renderDescription(); $results[$capability] = $global[$policy]->renderDescription($icon);
continue; continue;
} }
@ -44,7 +45,7 @@ final class PhabricatorPolicyQuery extends PhabricatorQuery {
->execute(); ->execute();
} }
$results[$capability] = $policies[$policy]->renderDescription(); $results[$capability] = $policies[$policy]->renderDescription($icon);
} }
return $results; return $results;

View file

@ -44,7 +44,7 @@ final class PonderQuestionViewController extends PonderController {
->setActionURI("/ponder/answer/add/"); ->setActionURI("/ponder/answer/add/");
} }
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($question->getTitle()); ->setHeader($question->getTitle());
$actions = $this->buildActionListView($question); $actions = $this->buildActionListView($question);
@ -251,7 +251,7 @@ final class PonderQuestionViewController extends PonderController {
$out[] = phutil_tag('br'); $out[] = phutil_tag('br');
$out[] = phutil_tag('br'); $out[] = phutil_tag('br');
$out[] = id(new PhabricatorHeaderView()) $out[] = id(new PHUIHeaderView())
->setHeader($this->getHandle($author_phid)->getFullName()) ->setHeader($this->getHandle($author_phid)->getFullName())
->setImage($this->getHandle($author_phid)->getImageURI()); ->setImage($this->getHandle($author_phid)->getImageURI());

View file

@ -21,7 +21,7 @@ final class PonderAddAnswerView extends AphrontView {
$question = $this->question; $question = $this->question;
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader(pht('Add Answer')); ->setHeader(pht('Add Answer'));
$form = new AphrontFormView(); $form = new AphrontFormView();

View file

@ -59,7 +59,7 @@ final class PhabricatorProjectProfileController
$tasks, $tasks,
$content); $content);
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($project->getName()) ->setHeader($project->getName())
->setSubheader(phutil_utf8_shorten($profile->getBlurb(), 1024)) ->setSubheader(phutil_utf8_shorten($profile->getBlurb(), 1024))
->setImage($picture); ->setImage($picture);

View file

@ -98,7 +98,7 @@ final class ReleephBranchViewController extends ReleephProjectController
$id = $branch->getID(); $id = $branch->getID();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($branch->getDisplayName()); ->setHeader($branch->getDisplayName());
if (!$branch->getIsActive()) { if (!$branch->getIsActive()) {

View file

@ -155,7 +155,7 @@ final class ReleephProjectViewController extends ReleephProjectController
$id = $project->getID(); $id = $project->getID();
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($project->getName()); ->setHeader($project->getName());
if (!$project->getIsActive()) { if (!$project->getIsActive()) {

View file

@ -54,7 +54,7 @@ final class ReleephRequestViewController extends ReleephProjectController {
->setTransactions($xactions) ->setTransactions($xactions)
->setMarkupEngine($engine); ->setMarkupEngine($engine);
$add_comment_header = id(new PhabricatorHeaderView()) $add_comment_header = id(new PHUIHeaderView())
->setHeader('Plea or yield'); ->setHeader('Plea or yield');
$draft = PhabricatorDraft::newFromUserAndKey( $draft = PhabricatorDraft::newFromUserAndKey(

View file

@ -30,7 +30,7 @@ final class PhabricatorSettingsPanelExternalAccounts
->needImages(true) ->needImages(true)
->execute(); ->execute();
$linked_head = id(new PhabricatorHeaderView()) $linked_head = id(new PHUIHeaderView())
->setHeader(pht('Linked Accounts and Authentication')); ->setHeader(pht('Linked Accounts and Authentication'));
$linked = id(new PHUIObjectItemListView()) $linked = id(new PHUIObjectItemListView())
@ -92,7 +92,7 @@ final class PhabricatorSettingsPanelExternalAccounts
$linked->addItem($item); $linked->addItem($item);
} }
$linkable_head = id(new PhabricatorHeaderView()) $linkable_head = id(new PHUIHeaderView())
->setHeader(pht('Add External Account')); ->setHeader(pht('Add External Account'));
$linkable = id(new PHUIObjectItemListView()) $linkable = id(new PHUIObjectItemListView())

View file

@ -152,7 +152,7 @@ final class PhabricatorSettingsPanelSSHKeys
->addCancelButton($this->getPanelURI()) ->addCancelButton($this->getPanelURI())
->setValue($save)); ->setValue($save));
$header_title = new PhabricatorHeaderView(); $header_title = new PHUIHeaderView();
$header_title->setHeader($header); $header_title->setHeader($header);
return id(new AphrontNullView()) return id(new AphrontNullView())

View file

@ -41,10 +41,10 @@ final class PhabricatorSlowvotePollController
)); ));
} }
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader($poll->getQuestion()); ->setHeader($poll->getQuestion());
$xaction_header = id(new PhabricatorHeaderView()) $xaction_header = id(new PHUIHeaderView())
->setHeader(pht('Ongoing Deliberations')); ->setHeader(pht('Ongoing Deliberations'));
$actions = $this->buildActionView($poll); $actions = $this->buildActionView($poll);
@ -166,7 +166,7 @@ final class PhabricatorSlowvotePollController
$is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business'); $is_serious = PhabricatorEnv::getEnvConfig('phabricator.serious-business');
$add_comment_header = id(new PhabricatorHeaderView()) $add_comment_header = id(new PHUIHeaderView())
->setHeader( ->setHeader(
$is_serious $is_serious
? pht('Add Comment') ? pht('Add Comment')

View file

@ -58,13 +58,13 @@ final class PHUIBoxExample extends PhabricatorUIExample {
->addPadding(PHUI::PADDING_LARGE) ->addPadding(PHUI::PADDING_LARGE)
->addMargin(PHUI::MARGIN_LARGE_BOTTOM)); ->addMargin(PHUI::MARGIN_LARGE_BOTTOM));
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader(pht('Plain Box')); ->setHeader(pht('Plain Box'));
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader(pht('Plain Box with space')); ->setHeader(pht('Plain Box with space'));
$head3 = id(new PhabricatorHeaderView()) $head3 = id(new PHUIHeaderView())
->setHeader(pht('Shadow Box with space')); ->setHeader(pht('Shadow Box with space'));
$wrap1 = id(new PHUIBoxView()) $wrap1 = id(new PHUIBoxView())

View file

@ -151,16 +151,16 @@ final class PHUIButtonExample extends PhabricatorUIExample {
// Set it and forget it // Set it and forget it
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader('phutil_tag'); ->setHeader('phutil_tag');
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader('PHUIButtonView'); ->setHeader('PHUIButtonView');
$head3 = id(new PhabricatorHeaderView()) $head3 = id(new PHUIHeaderView())
->setHeader('Icon Buttons'); ->setHeader('Icon Buttons');
$head4 = id(new PhabricatorHeaderView()) $head4 = id(new PHUIHeaderView())
->setHeader('Big Icon Buttons'); ->setHeader('Big Icon Buttons');
$wrap1 = id(new PHUIBoxView()) $wrap1 = id(new PHUIBoxView())

View file

@ -110,13 +110,13 @@ final class PHUIColorPalletteExample extends PhabricatorUIExample {
->setShadow(true) ->setShadow(true)
->addPadding(PHUI::PADDING_LARGE); ->addPadding(PHUI::PADDING_LARGE);
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader(pht('Greys')); ->setHeader(pht('Greys'));
$head1b = id(new PhabricatorHeaderView()) $head1b = id(new PHUIHeaderView())
->setHeader(pht('Blues')); ->setHeader(pht('Blues'));
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader(pht('Colors')); ->setHeader(pht('Colors'));
$wrap1 = id(new PHUIBoxView()) $wrap1 = id(new PHUIBoxView())

View file

@ -51,7 +51,7 @@ final class PHUIDocumentExample extends PhabricatorUIExample {
$divider = id(new PHUIListItemView) $divider = id(new PHUIListItemView)
->setType(PHUIListItemView::TYPE_DIVIDER); ->setType(PHUIListItemView::TYPE_DIVIDER);
$header = id(new PhabricatorHeaderView()) $header = id(new PHUIHeaderView())
->setHeader('Installation'); ->setHeader('Installation');
$label1 = id(new PHUIListItemView()) $label1 = id(new PHUIListItemView())

View file

@ -132,22 +132,22 @@ final class PHUIFeedStoryExample extends PhabricatorUIExample {
->setUser($user); ->setUser($user);
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader(pht('Basic Story')); ->setHeader(pht('Basic Story'));
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader(pht('Title / Text Story')); ->setHeader(pht('Title / Text Story'));
$head3 = id(new PhabricatorHeaderView()) $head3 = id(new PHUIHeaderView())
->setHeader(pht('Token Story')); ->setHeader(pht('Token Story'));
$head4 = id(new PhabricatorHeaderView()) $head4 = id(new PHUIHeaderView())
->setHeader(pht('Action Story')); ->setHeader(pht('Action Story'));
$head5 = id(new PhabricatorHeaderView()) $head5 = id(new PHUIHeaderView())
->setHeader(pht('Status Story')); ->setHeader(pht('Status Story'));
$head6 = id(new PhabricatorHeaderView()) $head6 = id(new PHUIHeaderView())
->setHeader(pht('One Line Story')); ->setHeader(pht('One Line Story'));
$wrap1 = $wrap1 =

View file

@ -162,19 +162,19 @@ final class PHUIIconExample extends PhabricatorUIExample {
->addPadding(PHUI::PADDING_MEDIUM) ->addPadding(PHUI::PADDING_MEDIUM)
->setShadow(true)); ->setShadow(true));
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader(pht('Action Icons!')); ->setHeader(pht('Action Icons!'));
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader(pht('People!')); ->setHeader(pht('People!'));
$head3 = id(new PhabricatorHeaderView()) $head3 = id(new PHUIHeaderView())
->setHeader(pht('Tokens')); ->setHeader(pht('Tokens'));
$head4 = id(new PhabricatorHeaderView()) $head4 = id(new PHUIHeaderView())
->setHeader(pht('Payments')); ->setHeader(pht('Payments'));
$head5 = id(new PhabricatorHeaderView()) $head5 = id(new PHUIHeaderView())
->setHeader(pht('Authentication')); ->setHeader(pht('Authentication'));
$wrap1 = id(new PHUIBoxView()) $wrap1 = id(new PHUIBoxView())

View file

@ -187,16 +187,16 @@ final class PHUIListExample extends PhabricatorUIExample {
->addMargin(PHUI::MARGIN_MEDIUM) ->addMargin(PHUI::MARGIN_MEDIUM)
->setShadow(true)); ->setShadow(true));
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader(pht('Unstyled')); ->setHeader(pht('Unstyled'));
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader(pht('Side Navigation')); ->setHeader(pht('Side Navigation'));
$head3 = id(new PhabricatorHeaderView()) $head3 = id(new PHUIHeaderView())
->setHeader(pht('Top Navigation')); ->setHeader(pht('Top Navigation'));
$head4 = id(new PhabricatorHeaderView()) $head4 = id(new PHUIHeaderView())
->setHeader(pht('Action Menu')); ->setHeader(pht('Action Menu'));
$wrap1 = id(new PHUIBoxView()) $wrap1 = id(new PHUIBoxView())

View file

@ -22,7 +22,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out = array(); $out = array();
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Basic List')); ->setHeader(pht('Basic List'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
@ -48,7 +48,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Empty List')); ->setHeader(pht('Empty List'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
@ -57,7 +57,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Stacked List')); ->setHeader(pht('Stacked List'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
$list->setStackable(true); $list->setStackable(true);
@ -81,7 +81,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Plain List')); ->setHeader(pht('Plain List'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
$list->setPlain(true); $list->setPlain(true);
@ -110,7 +110,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Card List')); ->setHeader(pht('Card List'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
$list->setCards(true); $list->setCards(true);
@ -157,7 +157,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Grippable List')); ->setHeader(pht('Grippable List'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
$list->setCards(true); $list->setCards(true);
@ -189,7 +189,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('List With Actions')); ->setHeader(pht('List With Actions'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
@ -223,7 +223,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Extras')); ->setHeader(pht('Extras'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
@ -268,7 +268,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Effects')); ->setHeader(pht('Effects'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();
@ -303,7 +303,7 @@ final class PHUIObjectItemListExample extends PhabricatorUIExample {
$out[] = array($head, $list); $out[] = array($head, $list);
$head = id(new PhabricatorHeaderView()) $head = id(new PHUIHeaderView())
->setHeader(pht('Colors')); ->setHeader(pht('Colors'));
$list = new PHUIObjectItemListView(); $list = new PHUIObjectItemListView();

View file

@ -73,7 +73,7 @@ final class PHUITextExample extends PhabricatorUIExample {
->setShadow(true) ->setShadow(true)
->addPadding(PHUI::PADDING_MEDIUM); ->addPadding(PHUI::PADDING_MEDIUM);
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader(pht('Basic Colors')); ->setHeader(pht('Basic Colors'));
$wrap1 = id(new PHUIBoxView()) $wrap1 = id(new PHUIBoxView())
@ -85,7 +85,7 @@ final class PHUITextExample extends PhabricatorUIExample {
->setShadow(true) ->setShadow(true)
->addPadding(PHUI::PADDING_MEDIUM); ->addPadding(PHUI::PADDING_MEDIUM);
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader(pht('Basic Transforms')); ->setHeader(pht('Basic Transforms'));
$wrap2 = id(new PHUIBoxView()) $wrap2 = id(new PHUIBoxView())

View file

@ -161,13 +161,13 @@ final class PHUIWorkboardExample extends PhabricatorUIExample {
->addAction($person2) ->addAction($person2)
->addAction($person3); ->addAction($person3);
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader(pht('Fixed Panel')); ->setHeader(pht('Fixed Panel'));
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader(pht('Fluid Panel')); ->setHeader(pht('Fluid Panel'));
$head3 = id(new PhabricatorHeaderView()) $head3 = id(new PHUIHeaderView())
->setHeader(pht('Action Panel')); ->setHeader(pht('Action Panel'));
$wrap1 = id(new PHUIBoxView()) $wrap1 = id(new PHUIBoxView())

View file

@ -13,7 +13,7 @@ final class PhabricatorActionHeaderExample extends PhabricatorUIExample {
public function renderExample() { public function renderExample() {
/* Colors */ /* Colors */
$title1 = id(new PhabricatorHeaderView()) $title1 = id(new PHUIHeaderView())
->setHeader(pht('Header Plain')); ->setHeader(pht('Header Plain'));
$header1 = id(new PhabricatorActionHeaderView()) $header1 = id(new PhabricatorActionHeaderView())
@ -54,7 +54,7 @@ final class PhabricatorActionHeaderExample extends PhabricatorUIExample {
->addMargin(PHUI::MARGIN_LARGE); ->addMargin(PHUI::MARGIN_LARGE);
/* Policy Icons */ /* Policy Icons */
$title2 = id(new PhabricatorHeaderView()) $title2 = id(new PHUIHeaderView())
->setHeader(pht('With Policy Icons')); ->setHeader(pht('With Policy Icons'));
$header1 = id(new PhabricatorActionHeaderView()) $header1 = id(new PhabricatorActionHeaderView())
@ -102,7 +102,7 @@ final class PhabricatorActionHeaderExample extends PhabricatorUIExample {
/* Action Icons */ /* Action Icons */
$title3 = id(new PhabricatorHeaderView()) $title3 = id(new PHUIHeaderView())
->setHeader(pht('With Action Icons')); ->setHeader(pht('With Action Icons'));
$action1 = new PHUIIconView(); $action1 = new PHUIIconView();
@ -186,7 +186,7 @@ final class PhabricatorActionHeaderExample extends PhabricatorUIExample {
->addMargin(PHUI::MARGIN_LARGE); ->addMargin(PHUI::MARGIN_LARGE);
/* Action Icons */ /* Action Icons */
$title4 = id(new PhabricatorHeaderView()) $title4 = id(new PHUIHeaderView())
->setHeader(pht('With Tags')); ->setHeader(pht('With Tags'));
$tag1 = id(new PhabricatorTagView()) $tag1 = id(new PhabricatorTagView())

View file

@ -31,14 +31,14 @@ final class PhabricatorMultiColumnExample extends PhabricatorUIExample {
), ),
'Army of Darkness'); 'Army of Darkness');
$head1 = id(new PhabricatorHeaderView()) $head1 = id(new PHUIHeaderView())
->setHeader(pht('2 Column Fixed')); ->setHeader(pht('2 Column Fixed'));
$layout1 = id(new AphrontMultiColumnView()) $layout1 = id(new AphrontMultiColumnView())
->addColumn($column1) ->addColumn($column1)
->addColumn($column2) ->addColumn($column2)
->setGutter(AphrontMultiColumnView::GUTTER_MEDIUM); ->setGutter(AphrontMultiColumnView::GUTTER_MEDIUM);
$head2 = id(new PhabricatorHeaderView()) $head2 = id(new PHUIHeaderView())
->setHeader(pht('2 Column Fluid')); ->setHeader(pht('2 Column Fluid'));
$layout2 = id(new AphrontMultiColumnView()) $layout2 = id(new AphrontMultiColumnView())
->addColumn($column1) ->addColumn($column1)
@ -46,7 +46,7 @@ final class PhabricatorMultiColumnExample extends PhabricatorUIExample {
->setFluidLayout(true) ->setFluidLayout(true)
->setGutter(AphrontMultiColumnView::GUTTER_MEDIUM); ->setGutter(AphrontMultiColumnView::GUTTER_MEDIUM);
$head3 = id(new PhabricatorHeaderView()) $head3 = id(new PHUIHeaderView())
->setHeader(pht('4 Column Fixed')); ->setHeader(pht('4 Column Fixed'));
$layout3 = id(new AphrontMultiColumnView()) $layout3 = id(new AphrontMultiColumnView())
->addColumn($column1) ->addColumn($column1)
@ -55,7 +55,7 @@ final class PhabricatorMultiColumnExample extends PhabricatorUIExample {
->addColumn($column2) ->addColumn($column2)
->setGutter(AphrontMultiColumnView::GUTTER_SMALL); ->setGutter(AphrontMultiColumnView::GUTTER_SMALL);
$head4 = id(new PhabricatorHeaderView()) $head4 = id(new PHUIHeaderView())
->setHeader(pht('4 Column Fluid')); ->setHeader(pht('4 Column Fluid'));
$layout4 = id(new AphrontMultiColumnView()) $layout4 = id(new AphrontMultiColumnView())
->addColumn($column1) ->addColumn($column1)
@ -86,7 +86,7 @@ final class PhabricatorMultiColumnExample extends PhabricatorUIExample {
$saturday = hsprintf('<strong>Saturday</strong><br /><br />StarCraft II'. $saturday = hsprintf('<strong>Saturday</strong><br /><br />StarCraft II'.
'<br />All<br />Damn<br />Day'); '<br />All<br />Damn<br />Day');
$head5 = id(new PhabricatorHeaderView()) $head5 = id(new PHUIHeaderView())
->setHeader(pht('7 Column Fluid')); ->setHeader(pht('7 Column Fluid'));
$layout5 = id(new AphrontMultiColumnView()) $layout5 = id(new AphrontMultiColumnView())
->addColumn($sunday) ->addColumn($sunday)
@ -153,7 +153,7 @@ final class PhabricatorMultiColumnExample extends PhabricatorUIExample {
$billing_title = pht('Billing Address'); $billing_title = pht('Billing Address');
$cc_title = pht('Payment Information'); $cc_title = pht('Payment Information');
$head6 = id(new PhabricatorHeaderView()) $head6 = id(new PHUIHeaderView())
->setHeader(pht('Let\'s Go Shopping')); ->setHeader(pht('Let\'s Go Shopping'));
$layout6 = id(new AphrontMultiColumnView()) $layout6 = id(new AphrontMultiColumnView())
->addColumn(hsprintf('<h1>%s</h1>%s', $shipping_title, $shipping)) ->addColumn(hsprintf('<h1>%s</h1>%s', $shipping_title, $shipping))

View file

@ -54,7 +54,7 @@ final class PhabricatorPropertyListExample extends PhabricatorUIExample {
'haiku. it is very bad.<br />'. 'haiku. it is very bad.<br />'.
'what did you expect?')); 'what did you expect?'));
$edge_cases_header = id(new PhabricatorHeaderView()) $edge_cases_header = id(new PHUIHeaderView())
->setHeader(pht('Edge Cases')); ->setHeader(pht('Edge Cases'));
$edge_cases_view = new PhabricatorPropertyListView(); $edge_cases_view = new PhabricatorPropertyListView();

View file

@ -84,7 +84,7 @@ final class PhabricatorTagExample extends PhabricatorUIExample {
->addPadding(PHUI::PADDING_LARGE) ->addPadding(PHUI::PADDING_LARGE)
->addMargin(PHUI::MARGIN_LARGE); ->addMargin(PHUI::MARGIN_LARGE);
$header1 = id(new PhabricatorHeaderView()) $header1 = id(new PHUIHeaderView())
->setHeader('Colors'); ->setHeader('Colors');
$colors = PhabricatorTagView::getColors(); $colors = PhabricatorTagView::getColors();
@ -103,7 +103,7 @@ final class PhabricatorTagExample extends PhabricatorUIExample {
->addPadding(PHUI::PADDING_LARGE) ->addPadding(PHUI::PADDING_LARGE)
->addMargin(PHUI::MARGIN_LARGE); ->addMargin(PHUI::MARGIN_LARGE);
$header2 = id(new PhabricatorHeaderView()) $header2 = id(new PHUIHeaderView())
->setHeader('Holidays?'); ->setHeader('Holidays?');

Some files were not shown because too many files have changed in this diff Show more