1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-29 08:50:58 +01:00

Move PhabricatorHovercard to PHUIHovercard

Summary: No UI changes, just some search and replace for UI consistency.

Test Plan: Test person and object hovercards still work. UIExamples too.

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: Korvin

Differential Revision: https://secure.phabricator.com/D15172
This commit is contained in:
Chad Little 2016-02-03 16:26:30 +00:00 committed by chad
parent d156da3402
commit 6bb24e1d0c
18 changed files with 81 additions and 81 deletions

View file

@ -8,7 +8,7 @@
return array( return array(
'names' => array( 'names' => array(
'core.pkg.css' => 'e33b14a4', 'core.pkg.css' => 'e33b14a4',
'core.pkg.js' => '53c6a7c5', 'core.pkg.js' => '7214314b',
'darkconsole.pkg.js' => 'e7393ebb', 'darkconsole.pkg.js' => 'e7393ebb',
'differential.pkg.css' => '2de124c9', 'differential.pkg.css' => '2de124c9',
'differential.pkg.js' => '5c2ba922', 'differential.pkg.js' => '5c2ba922',
@ -112,7 +112,6 @@ return array(
'rsrc/css/font/font-lato.css' => 'c7ccd872', 'rsrc/css/font/font-lato.css' => 'c7ccd872',
'rsrc/css/font/phui-font-icon-base.css' => 'ecbbb4c2', 'rsrc/css/font/phui-font-icon-base.css' => 'ecbbb4c2',
'rsrc/css/layout/phabricator-filetree-view.css' => 'fccf9f82', 'rsrc/css/layout/phabricator-filetree-view.css' => 'fccf9f82',
'rsrc/css/layout/phabricator-hovercard-view.css' => '1239cd52',
'rsrc/css/layout/phabricator-side-menu-view.css' => '3a3d9f41', 'rsrc/css/layout/phabricator-side-menu-view.css' => '3a3d9f41',
'rsrc/css/layout/phabricator-source-code-view.css' => 'cbeef983', 'rsrc/css/layout/phabricator-source-code-view.css' => 'cbeef983',
'rsrc/css/phui/calendar/phui-calendar-day.css' => 'd1cf6f93', 'rsrc/css/phui/calendar/phui-calendar-day.css' => 'd1cf6f93',
@ -135,6 +134,7 @@ return array(
'rsrc/css/phui/phui-form-view.css' => '4a1a0f5e', 'rsrc/css/phui/phui-form-view.css' => '4a1a0f5e',
'rsrc/css/phui/phui-form.css' => '0b98e572', 'rsrc/css/phui/phui-form.css' => '0b98e572',
'rsrc/css/phui/phui-header-view.css' => 'd53cc835', 'rsrc/css/phui/phui-header-view.css' => 'd53cc835',
'rsrc/css/phui/phui-hovercard.css' => '5684c081',
'rsrc/css/phui/phui-icon-set-selector.css' => '1ab67aad', 'rsrc/css/phui/phui-icon-set-selector.css' => '1ab67aad',
'rsrc/css/phui/phui-icon.css' => '3f33ab57', 'rsrc/css/phui/phui-icon.css' => '3f33ab57',
'rsrc/css/phui/phui-image-mask.css' => '5a8b09c8', 'rsrc/css/phui/phui-image-mask.css' => '5a8b09c8',
@ -448,7 +448,7 @@ return array(
'rsrc/js/core/DragAndDropFileUpload.js' => 'ad10aeac', 'rsrc/js/core/DragAndDropFileUpload.js' => 'ad10aeac',
'rsrc/js/core/DraggableList.js' => '8905523d', 'rsrc/js/core/DraggableList.js' => '8905523d',
'rsrc/js/core/FileUpload.js' => '477359c8', 'rsrc/js/core/FileUpload.js' => '477359c8',
'rsrc/js/core/Hovercard.js' => 'c6f720ff', 'rsrc/js/core/Hovercard.js' => '1bd28176',
'rsrc/js/core/KeyboardShortcut.js' => '1ae869f2', 'rsrc/js/core/KeyboardShortcut.js' => '1ae869f2',
'rsrc/js/core/KeyboardShortcutManager.js' => 'c1700f6f', 'rsrc/js/core/KeyboardShortcutManager.js' => 'c1700f6f',
'rsrc/js/core/MultirowRowManager.js' => 'b5d57730', 'rsrc/js/core/MultirowRowManager.js' => 'b5d57730',
@ -474,7 +474,7 @@ return array(
'rsrc/js/core/behavior-global-drag-and-drop.js' => 'c8e57404', 'rsrc/js/core/behavior-global-drag-and-drop.js' => 'c8e57404',
'rsrc/js/core/behavior-high-security-warning.js' => 'a464fe03', 'rsrc/js/core/behavior-high-security-warning.js' => 'a464fe03',
'rsrc/js/core/behavior-history-install.js' => '7ee2b591', 'rsrc/js/core/behavior-history-install.js' => '7ee2b591',
'rsrc/js/core/behavior-hovercard.js' => '66dd6e9e', 'rsrc/js/core/behavior-hovercard.js' => 'bcaccd64',
'rsrc/js/core/behavior-keyboard-pager.js' => 'a8da01f0', 'rsrc/js/core/behavior-keyboard-pager.js' => 'a8da01f0',
'rsrc/js/core/behavior-keyboard-shortcuts.js' => 'd75709e6', 'rsrc/js/core/behavior-keyboard-shortcuts.js' => 'd75709e6',
'rsrc/js/core/behavior-lightbox-attachments.js' => 'f8ba29d7', 'rsrc/js/core/behavior-lightbox-attachments.js' => 'f8ba29d7',
@ -630,7 +630,6 @@ return array(
'javelin-behavior-phabricator-file-tree' => '88236f00', 'javelin-behavior-phabricator-file-tree' => '88236f00',
'javelin-behavior-phabricator-gesture' => '3ab51e2c', 'javelin-behavior-phabricator-gesture' => '3ab51e2c',
'javelin-behavior-phabricator-gesture-example' => '558829c2', 'javelin-behavior-phabricator-gesture-example' => '558829c2',
'javelin-behavior-phabricator-hovercards' => '66dd6e9e',
'javelin-behavior-phabricator-keyboard-pager' => 'a8da01f0', 'javelin-behavior-phabricator-keyboard-pager' => 'a8da01f0',
'javelin-behavior-phabricator-keyboard-shortcuts' => 'd75709e6', 'javelin-behavior-phabricator-keyboard-shortcuts' => 'd75709e6',
'javelin-behavior-phabricator-line-linker' => '1499a8cb', 'javelin-behavior-phabricator-line-linker' => '1499a8cb',
@ -649,6 +648,7 @@ return array(
'javelin-behavior-pholio-mock-edit' => '246dc085', 'javelin-behavior-pholio-mock-edit' => '246dc085',
'javelin-behavior-pholio-mock-view' => 'fbe497e7', 'javelin-behavior-pholio-mock-view' => 'fbe497e7',
'javelin-behavior-phui-dropdown-menu' => '54733475', 'javelin-behavior-phui-dropdown-menu' => '54733475',
'javelin-behavior-phui-hovercards' => 'bcaccd64',
'javelin-behavior-phui-object-box-tabs' => '2bfa2836', 'javelin-behavior-phui-object-box-tabs' => '2bfa2836',
'javelin-behavior-phui-profile-menu' => '12884df9', 'javelin-behavior-phui-profile-menu' => '12884df9',
'javelin-behavior-policy-control' => 'ae45872f', 'javelin-behavior-policy-control' => 'ae45872f',
@ -747,8 +747,6 @@ return array(
'phabricator-file-upload' => '477359c8', 'phabricator-file-upload' => '477359c8',
'phabricator-filetree-view-css' => 'fccf9f82', 'phabricator-filetree-view-css' => 'fccf9f82',
'phabricator-flag-css' => '5337623f', 'phabricator-flag-css' => '5337623f',
'phabricator-hovercard' => 'c6f720ff',
'phabricator-hovercard-view-css' => '1239cd52',
'phabricator-keyboard-shortcut' => '1ae869f2', 'phabricator-keyboard-shortcut' => '1ae869f2',
'phabricator-keyboard-shortcut-manager' => 'c1700f6f', 'phabricator-keyboard-shortcut-manager' => 'c1700f6f',
'phabricator-main-menu-view' => 'd00a795a', 'phabricator-main-menu-view' => 'd00a795a',
@ -810,6 +808,8 @@ return array(
'phui-form-css' => '0b98e572', 'phui-form-css' => '0b98e572',
'phui-form-view-css' => '4a1a0f5e', 'phui-form-view-css' => '4a1a0f5e',
'phui-header-view-css' => 'd53cc835', 'phui-header-view-css' => 'd53cc835',
'phui-hovercard' => '1bd28176',
'phui-hovercard-view-css' => '5684c081',
'phui-icon-set-selector-css' => '1ab67aad', 'phui-icon-set-selector-css' => '1ab67aad',
'phui-icon-view-css' => '3f33ab57', 'phui-icon-view-css' => '3f33ab57',
'phui-image-mask-css' => '5a8b09c8', 'phui-image-mask-css' => '5a8b09c8',
@ -970,6 +970,13 @@ return array(
'javelin-dom', 'javelin-dom',
'javelin-typeahead-normalizer', 'javelin-typeahead-normalizer',
), ),
'1bd28176' => array(
'javelin-install',
'javelin-dom',
'javelin-vector',
'javelin-request',
'javelin-uri',
),
'1d45c74d' => array( '1d45c74d' => array(
'javelin-behavior', 'javelin-behavior',
'javelin-dom', 'javelin-dom',
@ -1312,13 +1319,6 @@ return array(
'javelin-request', 'javelin-request',
'javelin-workflow', 'javelin-workflow',
), ),
'66dd6e9e' => array(
'javelin-behavior',
'javelin-behavior-device',
'javelin-stratcom',
'javelin-vector',
'phabricator-hovercard',
),
68140031 => array( 68140031 => array(
'phui-workcard-view-css', 'phui-workcard-view-css',
), ),
@ -1755,6 +1755,13 @@ return array(
'b6b0d1bb' => array( 'b6b0d1bb' => array(
'phui-inline-comment-view-css', 'phui-inline-comment-view-css',
), ),
'bcaccd64' => array(
'javelin-behavior',
'javelin-behavior-device',
'javelin-stratcom',
'javelin-vector',
'phui-hovercard',
),
'bd4c8dca' => array( 'bd4c8dca' => array(
'javelin-install', 'javelin-install',
'javelin-util', 'javelin-util',
@ -1788,13 +1795,6 @@ return array(
'javelin-dom', 'javelin-dom',
'javelin-vector', 'javelin-vector',
), ),
'c6f720ff' => array(
'javelin-install',
'javelin-dom',
'javelin-vector',
'javelin-request',
'javelin-uri',
),
'c72aa091' => array( 'c72aa091' => array(
'javelin-behavior', 'javelin-behavior',
'javelin-dom', 'javelin-dom',
@ -2220,8 +2220,8 @@ return array(
'phabricator-file-upload', 'phabricator-file-upload',
'javelin-behavior-global-drag-and-drop', 'javelin-behavior-global-drag-and-drop',
'javelin-behavior-phabricator-reveal-content', 'javelin-behavior-phabricator-reveal-content',
'phabricator-hovercard', 'phui-hovercard',
'javelin-behavior-phabricator-hovercards', 'javelin-behavior-phui-hovercards',
'javelin-color', 'javelin-color',
'javelin-fx', 'javelin-fx',
'phabricator-draggable-list', 'phabricator-draggable-list',

View file

@ -59,8 +59,8 @@ return array(
'phabricator-file-upload', 'phabricator-file-upload',
'javelin-behavior-global-drag-and-drop', 'javelin-behavior-global-drag-and-drop',
'javelin-behavior-phabricator-reveal-content', 'javelin-behavior-phabricator-reveal-content',
'phabricator-hovercard', 'phui-hovercard',
'javelin-behavior-phabricator-hovercards', 'javelin-behavior-phui-hovercards',
'javelin-color', 'javelin-color',
'javelin-fx', 'javelin-fx',
'phabricator-draggable-list', 'phabricator-draggable-list',

View file

@ -1493,6 +1493,8 @@ phutil_register_library_map(array(
'PHUIHandleTagListView' => 'applications/phid/view/PHUIHandleTagListView.php', 'PHUIHandleTagListView' => 'applications/phid/view/PHUIHandleTagListView.php',
'PHUIHandleView' => 'applications/phid/view/PHUIHandleView.php', 'PHUIHandleView' => 'applications/phid/view/PHUIHandleView.php',
'PHUIHeaderView' => 'view/phui/PHUIHeaderView.php', 'PHUIHeaderView' => 'view/phui/PHUIHeaderView.php',
'PHUIHovercardUIExample' => 'applications/uiexample/examples/PHUIHovercardUIExample.php',
'PHUIHovercardView' => 'view/phui/PHUIHovercardView.php',
'PHUIIconCircleView' => 'view/phui/PHUIIconCircleView.php', 'PHUIIconCircleView' => 'view/phui/PHUIIconCircleView.php',
'PHUIIconExample' => 'applications/uiexample/examples/PHUIIconExample.php', 'PHUIIconExample' => 'applications/uiexample/examples/PHUIIconExample.php',
'PHUIIconView' => 'view/phui/PHUIIconView.php', 'PHUIIconView' => 'view/phui/PHUIIconView.php',
@ -1585,6 +1587,7 @@ phutil_register_library_map(array(
'PasteSearchConduitAPIMethod' => 'applications/paste/conduit/PasteSearchConduitAPIMethod.php', 'PasteSearchConduitAPIMethod' => 'applications/paste/conduit/PasteSearchConduitAPIMethod.php',
'PeopleBrowseUserDirectoryCapability' => 'applications/people/capability/PeopleBrowseUserDirectoryCapability.php', 'PeopleBrowseUserDirectoryCapability' => 'applications/people/capability/PeopleBrowseUserDirectoryCapability.php',
'PeopleCreateUsersCapability' => 'applications/people/capability/PeopleCreateUsersCapability.php', 'PeopleCreateUsersCapability' => 'applications/people/capability/PeopleCreateUsersCapability.php',
'PeopleHovercardEngineExtension' => 'applications/people/engineextension/PeopleHovercardEngineExtension.php',
'PeopleUserLogGarbageCollector' => 'applications/people/garbagecollector/PeopleUserLogGarbageCollector.php', 'PeopleUserLogGarbageCollector' => 'applications/people/garbagecollector/PeopleUserLogGarbageCollector.php',
'Phabricator404Controller' => 'applications/base/controller/Phabricator404Controller.php', 'Phabricator404Controller' => 'applications/base/controller/Phabricator404Controller.php',
'PhabricatorAWSConfigOptions' => 'applications/config/option/PhabricatorAWSConfigOptions.php', 'PhabricatorAWSConfigOptions' => 'applications/config/option/PhabricatorAWSConfigOptions.php',
@ -2388,8 +2391,6 @@ phutil_register_library_map(array(
'PhabricatorHomeQuickCreateController' => 'applications/home/controller/PhabricatorHomeQuickCreateController.php', 'PhabricatorHomeQuickCreateController' => 'applications/home/controller/PhabricatorHomeQuickCreateController.php',
'PhabricatorHovercardEngineExtension' => 'applications/search/engineextension/PhabricatorHovercardEngineExtension.php', 'PhabricatorHovercardEngineExtension' => 'applications/search/engineextension/PhabricatorHovercardEngineExtension.php',
'PhabricatorHovercardEngineExtensionModule' => 'applications/search/engineextension/PhabricatorHovercardEngineExtensionModule.php', 'PhabricatorHovercardEngineExtensionModule' => 'applications/search/engineextension/PhabricatorHovercardEngineExtensionModule.php',
'PhabricatorHovercardUIExample' => 'applications/uiexample/examples/PhabricatorHovercardUIExample.php',
'PhabricatorHovercardView' => 'view/widget/hovercard/PhabricatorHovercardView.php',
'PhabricatorHunksManagementMigrateWorkflow' => 'applications/differential/management/PhabricatorHunksManagementMigrateWorkflow.php', 'PhabricatorHunksManagementMigrateWorkflow' => 'applications/differential/management/PhabricatorHunksManagementMigrateWorkflow.php',
'PhabricatorHunksManagementWorkflow' => 'applications/differential/management/PhabricatorHunksManagementWorkflow.php', 'PhabricatorHunksManagementWorkflow' => 'applications/differential/management/PhabricatorHunksManagementWorkflow.php',
'PhabricatorIDsSearchEngineExtension' => 'applications/search/engineextension/PhabricatorIDsSearchEngineExtension.php', 'PhabricatorIDsSearchEngineExtension' => 'applications/search/engineextension/PhabricatorIDsSearchEngineExtension.php',
@ -2735,7 +2736,6 @@ phutil_register_library_map(array(
'PhabricatorPeopleDisableController' => 'applications/people/controller/PhabricatorPeopleDisableController.php', 'PhabricatorPeopleDisableController' => 'applications/people/controller/PhabricatorPeopleDisableController.php',
'PhabricatorPeopleEmpowerController' => 'applications/people/controller/PhabricatorPeopleEmpowerController.php', 'PhabricatorPeopleEmpowerController' => 'applications/people/controller/PhabricatorPeopleEmpowerController.php',
'PhabricatorPeopleExternalPHIDType' => 'applications/people/phid/PhabricatorPeopleExternalPHIDType.php', 'PhabricatorPeopleExternalPHIDType' => 'applications/people/phid/PhabricatorPeopleExternalPHIDType.php',
'PhabricatorPeopleHovercardEngineExtension' => 'applications/people/engineextension/PhabricatorPeopleHovercardEngineExtension.php',
'PhabricatorPeopleIconSet' => 'applications/people/icon/PhabricatorPeopleIconSet.php', 'PhabricatorPeopleIconSet' => 'applications/people/icon/PhabricatorPeopleIconSet.php',
'PhabricatorPeopleInviteController' => 'applications/people/controller/PhabricatorPeopleInviteController.php', 'PhabricatorPeopleInviteController' => 'applications/people/controller/PhabricatorPeopleInviteController.php',
'PhabricatorPeopleInviteListController' => 'applications/people/controller/PhabricatorPeopleInviteListController.php', 'PhabricatorPeopleInviteListController' => 'applications/people/controller/PhabricatorPeopleInviteListController.php',
@ -5669,6 +5669,8 @@ phutil_register_library_map(array(
'PHUIHandleTagListView' => 'AphrontTagView', 'PHUIHandleTagListView' => 'AphrontTagView',
'PHUIHandleView' => 'AphrontView', 'PHUIHandleView' => 'AphrontView',
'PHUIHeaderView' => 'AphrontTagView', 'PHUIHeaderView' => 'AphrontTagView',
'PHUIHovercardUIExample' => 'PhabricatorUIExample',
'PHUIHovercardView' => 'AphrontView',
'PHUIIconCircleView' => 'AphrontTagView', 'PHUIIconCircleView' => 'AphrontTagView',
'PHUIIconExample' => 'PhabricatorUIExample', 'PHUIIconExample' => 'PhabricatorUIExample',
'PHUIIconView' => 'AphrontTagView', 'PHUIIconView' => 'AphrontTagView',
@ -5770,6 +5772,7 @@ phutil_register_library_map(array(
'PasteSearchConduitAPIMethod' => 'PhabricatorSearchEngineAPIMethod', 'PasteSearchConduitAPIMethod' => 'PhabricatorSearchEngineAPIMethod',
'PeopleBrowseUserDirectoryCapability' => 'PhabricatorPolicyCapability', 'PeopleBrowseUserDirectoryCapability' => 'PhabricatorPolicyCapability',
'PeopleCreateUsersCapability' => 'PhabricatorPolicyCapability', 'PeopleCreateUsersCapability' => 'PhabricatorPolicyCapability',
'PeopleHovercardEngineExtension' => 'PhabricatorHovercardEngineExtension',
'PeopleUserLogGarbageCollector' => 'PhabricatorGarbageCollector', 'PeopleUserLogGarbageCollector' => 'PhabricatorGarbageCollector',
'Phabricator404Controller' => 'PhabricatorController', 'Phabricator404Controller' => 'PhabricatorController',
'PhabricatorAWSConfigOptions' => 'PhabricatorApplicationConfigOptions', 'PhabricatorAWSConfigOptions' => 'PhabricatorApplicationConfigOptions',
@ -6717,8 +6720,6 @@ phutil_register_library_map(array(
'PhabricatorHomeQuickCreateController' => 'PhabricatorHomeController', 'PhabricatorHomeQuickCreateController' => 'PhabricatorHomeController',
'PhabricatorHovercardEngineExtension' => 'Phobject', 'PhabricatorHovercardEngineExtension' => 'Phobject',
'PhabricatorHovercardEngineExtensionModule' => 'PhabricatorConfigModule', 'PhabricatorHovercardEngineExtensionModule' => 'PhabricatorConfigModule',
'PhabricatorHovercardUIExample' => 'PhabricatorUIExample',
'PhabricatorHovercardView' => 'AphrontView',
'PhabricatorHunksManagementMigrateWorkflow' => 'PhabricatorHunksManagementWorkflow', 'PhabricatorHunksManagementMigrateWorkflow' => 'PhabricatorHunksManagementWorkflow',
'PhabricatorHunksManagementWorkflow' => 'PhabricatorManagementWorkflow', 'PhabricatorHunksManagementWorkflow' => 'PhabricatorManagementWorkflow',
'PhabricatorIDsSearchEngineExtension' => 'PhabricatorSearchEngineExtension', 'PhabricatorIDsSearchEngineExtension' => 'PhabricatorSearchEngineExtension',
@ -7109,7 +7110,6 @@ phutil_register_library_map(array(
'PhabricatorPeopleDisableController' => 'PhabricatorPeopleController', 'PhabricatorPeopleDisableController' => 'PhabricatorPeopleController',
'PhabricatorPeopleEmpowerController' => 'PhabricatorPeopleController', 'PhabricatorPeopleEmpowerController' => 'PhabricatorPeopleController',
'PhabricatorPeopleExternalPHIDType' => 'PhabricatorPHIDType', 'PhabricatorPeopleExternalPHIDType' => 'PhabricatorPHIDType',
'PhabricatorPeopleHovercardEngineExtension' => 'PhabricatorHovercardEngineExtension',
'PhabricatorPeopleIconSet' => 'PhabricatorIconSet', 'PhabricatorPeopleIconSet' => 'PhabricatorIconSet',
'PhabricatorPeopleInviteController' => 'PhabricatorPeopleController', 'PhabricatorPeopleInviteController' => 'PhabricatorPeopleController',
'PhabricatorPeopleInviteListController' => 'PhabricatorPeopleInviteController', 'PhabricatorPeopleInviteListController' => 'PhabricatorPeopleInviteController',

View file

@ -35,7 +35,7 @@ final class DifferentialHovercardEngineExtension
} }
public function renderHovercard( public function renderHovercard(
PhabricatorHovercardView $hovercard, PHUIHovercardView $hovercard,
PhabricatorObjectHandle $handle, PhabricatorObjectHandle $handle,
$object, $object,
$data) { $data) {

View file

@ -19,7 +19,7 @@ final class DiffusionHovercardEngineExtension
} }
public function renderHovercard( public function renderHovercard(
PhabricatorHovercardView $hovercard, PHUIHovercardView $hovercard,
PhabricatorObjectHandle $handle, PhabricatorObjectHandle $handle,
$commit, $commit,
$data) { $data) {

View file

@ -19,7 +19,7 @@ final class ManiphestHovercardEngineExtension
} }
public function renderHovercard( public function renderHovercard(
PhabricatorHovercardView $hovercard, PHUIHovercardView $hovercard,
PhabricatorObjectHandle $handle, PhabricatorObjectHandle $handle,
$task, $task,
$data) { $data) {

View file

@ -1,6 +1,6 @@
<?php <?php
final class PhabricatorPeopleHovercardEngineExtension final class PeopleHovercardEngineExtension
extends PhabricatorHovercardEngineExtension { extends PhabricatorHovercardEngineExtension {
const EXTENSIONKEY = 'people'; const EXTENSIONKEY = 'people';
@ -36,7 +36,7 @@ final class PhabricatorPeopleHovercardEngineExtension
} }
public function renderHovercard( public function renderHovercard(
PhabricatorHovercardView $hovercard, PHUIHovercardView $hovercard,
PhabricatorObjectHandle $handle, PhabricatorObjectHandle $handle,
$object, $object,
$data) { $data) {

View file

@ -93,7 +93,7 @@ final class PhabricatorMentionRemarkupRule extends PhutilRemarkupRule {
if ($exists) { if ($exists) {
$user = $actual_users[$username]; $user = $actual_users[$username];
Javelin::initBehavior('phabricator-hovercards'); Javelin::initBehavior('phui-hovercards');
// Check if the user has view access to the object she was mentioned in // Check if the user has view access to the object she was mentioned in
if ($context_object if ($context_object

View file

@ -276,7 +276,7 @@ final class PhabricatorObjectHandle
} }
public function renderHovercardLink($name = null) { public function renderHovercardLink($name = null) {
Javelin::initBehavior('phabricator-hovercards'); Javelin::initBehavior('phui-hovercards');
$attributes = array( $attributes = array(
'sigil' => 'hovercard', 'sigil' => 'hovercard',

View file

@ -56,7 +56,7 @@ final class PhabricatorSearchHovercardController
$handle = $handles[$phid]; $handle = $handles[$phid];
$object = idx($objects, $phid); $object = idx($objects, $phid);
$hovercard = id(new PhabricatorHovercardView()) $hovercard = id(new PHUIHovercardView())
->setUser($viewer) ->setUser($viewer)
->setObjectHandle($handle); ->setObjectHandle($handle);

View file

@ -32,7 +32,7 @@ abstract class PhabricatorHovercardEngineExtension extends Phobject {
} }
abstract public function renderHovercard( abstract public function renderHovercard(
PhabricatorHovercardView $hovercard, PHUIHovercardView $hovercard,
PhabricatorObjectHandle $handle, PhabricatorObjectHandle $handle,
$object, $object,
$data); $data);

View file

@ -1,6 +1,6 @@
<?php <?php
final class PhabricatorHovercardUIExample extends PhabricatorUIExample { final class PHUIHovercardUIExample extends PhabricatorUIExample {
public function getName() { public function getName() {
return pht('Hovercard'); return pht('Hovercard');
@ -8,8 +8,8 @@ final class PhabricatorHovercardUIExample extends PhabricatorUIExample {
public function getDescription() { public function getDescription() {
return pht( return pht(
"Use %s to render hovercards. Aren't I genius?", 'Use %s to render hovercards.',
phutil_tag('tt', array(), 'PhabricatorHovercardView')); phutil_tag('tt', array(), 'PHUIHovercardView'));
} }
public function renderExample() { public function renderExample() {
@ -24,7 +24,7 @@ final class PhabricatorHovercardUIExample extends PhabricatorUIExample {
pht('Introduce cooler Differential Revisions')); pht('Introduce cooler Differential Revisions'));
$panel = $this->createPanel(pht('Differential Hovercard')); $panel = $this->createPanel(pht('Differential Hovercard'));
$panel->appendChild(id(new PhabricatorHovercardView()) $panel->appendChild(id(new PHUIHovercardView())
->setObjectHandle($diff_handle) ->setObjectHandle($diff_handle)
->addField(pht('Author'), $user->getUsername()) ->addField(pht('Author'), $user->getUsername())
->addField(pht('Updated'), phabricator_datetime(time(), $user)) ->addField(pht('Updated'), phabricator_datetime(time(), $user))
@ -41,7 +41,7 @@ final class PhabricatorHovercardUIExample extends PhabricatorUIExample {
->setType(PHUITagView::TYPE_STATE) ->setType(PHUITagView::TYPE_STATE)
->setName(pht('Closed, Resolved')); ->setName(pht('Closed, Resolved'));
$panel = $this->createPanel(pht('Maniphest Hovercard')); $panel = $this->createPanel(pht('Maniphest Hovercard'));
$panel->appendChild(id(new PhabricatorHovercardView()) $panel->appendChild(id(new PHUIHovercardView())
->setObjectHandle($task_handle) ->setObjectHandle($task_handle)
->setUser($user) ->setUser($user)
->addField(pht('Assigned to'), $user->getUsername()) ->addField(pht('Assigned to'), $user->getUsername())
@ -66,7 +66,7 @@ final class PhabricatorHovercardUIExample extends PhabricatorUIExample {
$user_handle->setImageURI( $user_handle->setImageURI(
celerity_get_resource_uri('/rsrc/image/people/washington.png')); celerity_get_resource_uri('/rsrc/image/people/washington.png'));
$panel = $this->createPanel(pht('Whatevery Hovercard')); $panel = $this->createPanel(pht('Whatevery Hovercard'));
$panel->appendChild(id(new PhabricatorHovercardView()) $panel->appendChild(id(new PHUIHovercardView())
->setObjectHandle($user_handle) ->setObjectHandle($user_handle)
->addField(pht('Status'), pht('Available')) ->addField(pht('Status'), pht('Available'))
->addField(pht('Member since'), '30. February 1750') ->addField(pht('Member since'), '30. February 1750')

View file

@ -157,7 +157,7 @@ final class PHUIFeedStoryView extends AphrontView {
public function render() { public function render() {
require_celerity_resource('phui-feed-story-css'); require_celerity_resource('phui-feed-story-css');
Javelin::initBehavior('phabricator-hovercards'); Javelin::initBehavior('phui-hovercards');
$body = null; $body = null;
$foot = null; $foot = null;

View file

@ -4,7 +4,7 @@
* The default one-for-all hovercard. We may derive from this one to create * The default one-for-all hovercard. We may derive from this one to create
* more specialized ones. * more specialized ones.
*/ */
final class PhabricatorHovercardView extends AphrontView { final class PHUIHovercardView extends AphrontView {
/** /**
* @var PhabricatorObjectHandle * @var PhabricatorObjectHandle
@ -78,7 +78,7 @@ final class PhabricatorHovercardView extends AphrontView {
$viewer = $this->getUser(); $viewer = $this->getUser();
$handle = $this->handle; $handle = $this->handle;
require_celerity_resource('phabricator-hovercard-view-css'); require_celerity_resource('phui-hovercard-view-css');
$title = array( $title = array(
id(new PHUISpacesNamespaceContextView()) id(new PHUISpacesNamespaceContextView())
@ -107,7 +107,7 @@ final class PhabricatorHovercardView extends AphrontView {
$body_title = $handle->getFullName(); $body_title = $handle->getFullName();
} }
$body[] = phutil_tag_div('phabricator-hovercard-body-header', $body_title); $body[] = phutil_tag_div('phui-hovercard-body-header', $body_title);
foreach ($this->fields as $field) { foreach ($this->fields as $field) {
$item = array( $item = array(
@ -115,7 +115,7 @@ final class PhabricatorHovercardView extends AphrontView {
': ', ': ',
phutil_tag('span', array(), $field['value']), phutil_tag('span', array(), $field['value']),
); );
$body[] = phutil_tag_div('phabricator-hovercard-body-item', $item); $body[] = phutil_tag_div('phui-hovercard-body-item', $item);
} }
if ($this->badges) { if ($this->badges) {
@ -125,7 +125,7 @@ final class PhabricatorHovercardView extends AphrontView {
$body[] = phutil_tag( $body[] = phutil_tag(
'div', 'div',
array( array(
'class' => 'phabricator-hovercard-body-item hovercard-badges', 'class' => 'phui-hovercard-body-item hovercard-badges',
), ),
$badges); $badges);
} }
@ -136,7 +136,7 @@ final class PhabricatorHovercardView extends AphrontView {
$body = phutil_tag( $body = phutil_tag(
'div', 'div',
array( array(
'class' => 'phabricator-hovercard-body-image', 'class' => 'phui-hovercard-body-image',
), ),
phutil_tag( phutil_tag(
'div', 'div',
@ -149,7 +149,7 @@ final class PhabricatorHovercardView extends AphrontView {
phutil_tag( phutil_tag(
'div', 'div',
array( array(
'class' => 'phabricator-hovercard-body-details', 'class' => 'phui-hovercard-body-details',
), ),
$body)); $body));
} }
@ -178,18 +178,18 @@ final class PhabricatorHovercardView extends AphrontView {
$tail = null; $tail = null;
if ($buttons) { if ($buttons) {
$tail = phutil_tag_div('phabricator-hovercard-tail', $buttons); $tail = phutil_tag_div('phui-hovercard-tail', $buttons);
} }
$hovercard = phutil_tag_div( $hovercard = phutil_tag_div(
'phabricator-hovercard-container', 'phui-hovercard-container',
array( array(
phutil_tag_div('phabricator-hovercard-head', $header), phutil_tag_div('phui-hovercard-head', $header),
phutil_tag_div('phabricator-hovercard-body grouped', $body), phutil_tag_div('phui-hovercard-body grouped', $body),
$tail, $tail,
)); ));
return phutil_tag_div('phabricator-hovercard-wrapper', $hovercard); return phutil_tag_div('phui-hovercard-wrapper', $hovercard);
} }
} }

View file

@ -122,7 +122,7 @@ final class PHUITagView extends AphrontTagView {
} }
if ($this->phid) { if ($this->phid) {
Javelin::initBehavior('phabricator-hovercards'); Javelin::initBehavior('phui-hovercards');
$attributes = array( $attributes = array(
'href' => $this->href, 'href' => $this->href,

View file

@ -1,22 +1,22 @@
/** /**
* @provides phabricator-hovercard-view-css * @provides phui-hovercard-view-css
*/ */
.jx-hovercard-container { .jx-hovercard-container {
position: absolute; position: absolute;
} }
.phabricator-hovercard-wrapper { .phui-hovercard-wrapper {
float: left; float: left;
width: 400px; width: 400px;
} }
.device-phone .phabricator-hovercard-wrapper { .device-phone .phui-hovercard-wrapper {
float: left; float: left;
width: 300px; width: 300px;
} }
.phabricator-hovercard-container { .phui-hovercard-container {
float: left; float: left;
width: 100%; width: 100%;
box-shadow: {$dropshadow}; box-shadow: {$dropshadow};
@ -25,29 +25,29 @@
background-color: #fff; background-color: #fff;
} }
.phabricator-hovercard-head .phui-header-shell { .phui-hovercard-head .phui-header-shell {
padding: 6px 8px 6px 12px; padding: 6px 8px 6px 12px;
background-color: {$bluebackground}; background-color: {$bluebackground};
border-top-left-radius: 3px; border-top-left-radius: 3px;
border-top-right-radius: 3px; border-top-right-radius: 3px;
} }
.phabricator-hovercard-head .phui-header-header { .phui-hovercard-head .phui-header-header {
font-size: 14px; font-size: 14px;
} }
.phabricator-hovercard-head .phui-tag-type-state { .phui-hovercard-head .phui-tag-type-state {
color: {$darkbluetext}; color: {$darkbluetext};
text-shadow: none; text-shadow: none;
font-weight: normal; font-weight: normal;
} }
.phabricator-hovercard-tags { .phui-hovercard-tags {
float: right; float: right;
white-space: normal; white-space: normal;
} }
.phabricator-hovercard-body { .phui-hovercard-body {
padding: 12px; padding: 12px;
color: {$darkgreytext}; color: {$darkgreytext};
border-bottom-right-radius: 3px; border-bottom-right-radius: 3px;
@ -55,26 +55,26 @@
position: relative; position: relative;
} }
.phabricator-hovercard-body-item { .phui-hovercard-body-item {
margin: 4px 0 0 0; margin: 4px 0 0 0;
} }
.phabricator-hovercard-body-header { .phui-hovercard-body-header {
font-size: 14px; font-size: 14px;
padding-bottom: 4px; padding-bottom: 4px;
color: {$darkgreytext}; color: {$darkgreytext};
line-height: 18px; line-height: 18px;
} }
.phabricator-hovercard-body .phabricator-hovercard-body-image { .phui-hovercard-body .phui-hovercard-body-image {
width: 58px; width: 58px;
} }
.phabricator-hovercard-body .phabricator-hovercard-body-details { .phui-hovercard-body .phui-hovercard-body-details {
margin-left: 58px; margin-left: 58px;
} }
.phabricator-hovercard-body .profile-header-picture-frame { .phui-hovercard-body .profile-header-picture-frame {
float: left; float: left;
width: 50px; width: 50px;
height: 50px; height: 50px;
@ -91,7 +91,7 @@
float: left; float: left;
} }
.phabricator-hovercard-tail { .phui-hovercard-tail {
width: 396px; width: 396px;
float: left; float: left;
padding: 2px; padding: 2px;
@ -100,7 +100,7 @@
border-bottom-right-radius: 3px; border-bottom-right-radius: 3px;
} }
.phabricator-hovercard-tail button, .phui-hovercard-tail button,
.phabricator-hovercard-tail a.button { .phui-hovercard-tail a.button {
margin: 3px; margin: 3px;
} }

View file

@ -4,7 +4,7 @@
* javelin-vector * javelin-vector
* javelin-request * javelin-request
* javelin-uri * javelin-uri
* @provides phabricator-hovercard * @provides phui-hovercard
* @javelin * @javelin
*/ */

View file

@ -1,14 +1,14 @@
/** /**
* @provides javelin-behavior-phabricator-hovercards * @provides javelin-behavior-phui-hovercards
* @requires javelin-behavior * @requires javelin-behavior
* javelin-behavior-device * javelin-behavior-device
* javelin-stratcom * javelin-stratcom
* javelin-vector * javelin-vector
* phabricator-hovercard * phui-hovercard
* @javelin * @javelin
*/ */
JX.behavior('phabricator-hovercards', function() { JX.behavior('phui-hovercards', function() {
// We listen for mousemove instead of mouseover to handle the case when user // We listen for mousemove instead of mouseover to handle the case when user
// scrolls with keyboard. We don't want to display hovercard if node gets // scrolls with keyboard. We don't want to display hovercard if node gets