Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15394543
D15154.id36586.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D15154.id36586.diff
View Options
diff --git a/src/applications/people/phid/PhabricatorPeopleUserPHIDType.php b/src/applications/people/phid/PhabricatorPeopleUserPHIDType.php
--- a/src/applications/people/phid/PhabricatorPeopleUserPHIDType.php
+++ b/src/applications/people/phid/PhabricatorPeopleUserPHIDType.php
@@ -54,8 +54,10 @@
$icon_icon = PhabricatorPeopleIconSet::getIconIcon($icon_key);
$subtitle = $profile->getDisplayTitle();
- $handle->setIcon($icon_icon);
- $handle->setSubtitle($subtitle);
+ $handle
+ ->setIcon($icon_icon)
+ ->setSubtitle($subtitle)
+ ->setTokenIcon('fa-user');
}
$availability = null;
diff --git a/src/applications/phid/PhabricatorObjectHandle.php b/src/applications/phid/PhabricatorObjectHandle.php
--- a/src/applications/phid/PhabricatorObjectHandle.php
+++ b/src/applications/phid/PhabricatorObjectHandle.php
@@ -28,6 +28,7 @@
private $objectName;
private $policyFiltered;
private $subtitle;
+ private $tokenIcon;
public function setIcon($icon) {
$this->icon = $icon;
@@ -86,6 +87,19 @@
return null;
}
+ public function setTokenIcon($icon) {
+ $this->tokenIcon = $icon;
+ return $this;
+ }
+
+ public function getTokenIcon() {
+ if ($this->tokenIcon !== null) {
+ return $this->tokenIcon;
+ }
+
+ return $this->getIcon();
+ }
+
public function getTypeIcon() {
if ($this->getPHIDType()) {
return $this->getPHIDType()->getTypeIcon();
diff --git a/src/applications/typeahead/view/PhabricatorTypeaheadTokenView.php b/src/applications/typeahead/view/PhabricatorTypeaheadTokenView.php
--- a/src/applications/typeahead/view/PhabricatorTypeaheadTokenView.php
+++ b/src/applications/typeahead/view/PhabricatorTypeaheadTokenView.php
@@ -32,7 +32,7 @@
$token = id(new PhabricatorTypeaheadTokenView())
->setKey($handle->getPHID())
->setValue($handle->getFullName())
- ->setIcon($handle->getIcon());
+ ->setIcon($handle->getTokenIcon());
if ($handle->isDisabled() ||
$handle->getStatus() == PhabricatorObjectHandle::STATUS_CLOSED) {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Mar 16, 11:54 PM (2 w, 2 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7453298
Default Alt Text
D15154.id36586.diff (2 KB)
Attached To
Mode
D15154: Always give users "fa-user" icons in tokenizers
Attached
Detach File
Event Timeline
Log In to Comment