@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Improve type and icon information in typeahead

Summary:
Ref T10289. This probably doesn't cover everything but should do a little bit better.

Although we should mabye just exlude milestones from this menu completely?

Test Plan: {F1093937}

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T10289

Differential Revision: https://secure.phabricator.com/D15191

+31 -16
+14 -13
resources/celerity/map.php
··· 8 8 return array( 9 9 'names' => array( 10 10 'core.pkg.css' => 'e33b14a4', 11 - 'core.pkg.js' => '7214314b', 11 + 'core.pkg.js' => 'ef5e33db', 12 12 'darkconsole.pkg.js' => 'e7393ebb', 13 13 'differential.pkg.css' => '2de124c9', 14 14 'differential.pkg.js' => '5c2ba922', ··· 490 490 'rsrc/js/core/behavior-reorder-applications.js' => '76b9fc3e', 491 491 'rsrc/js/core/behavior-reveal-content.js' => '60821bc7', 492 492 'rsrc/js/core/behavior-scrollbar.js' => '834a1173', 493 - 'rsrc/js/core/behavior-search-typeahead.js' => '0b7a4f6e', 493 + 'rsrc/js/core/behavior-search-typeahead.js' => '06c32383', 494 494 'rsrc/js/core/behavior-select-on-click.js' => '4e3e79a6', 495 495 'rsrc/js/core/behavior-time-typeahead.js' => 'f80d6bf0', 496 496 'rsrc/js/core/behavior-toggle-class.js' => '5d7c9f33', ··· 640 640 'javelin-behavior-phabricator-oncopy' => '2926fff2', 641 641 'javelin-behavior-phabricator-remarkup-assist' => '340c8eff', 642 642 'javelin-behavior-phabricator-reveal-content' => '60821bc7', 643 - 'javelin-behavior-phabricator-search-typeahead' => '0b7a4f6e', 643 + 'javelin-behavior-phabricator-search-typeahead' => '06c32383', 644 644 'javelin-behavior-phabricator-show-older-transactions' => 'dbbf48b6', 645 645 'javelin-behavior-phabricator-tooltips' => '3ee3408b', 646 646 'javelin-behavior-phabricator-transaction-comment-form' => 'b23b49e6', ··· 909 909 'javelin-stratcom', 910 910 'javelin-workflow', 911 911 ), 912 + '06c32383' => array( 913 + 'javelin-behavior', 914 + 'javelin-typeahead-ondemand-source', 915 + 'javelin-typeahead', 916 + 'javelin-dom', 917 + 'javelin-uri', 918 + 'javelin-util', 919 + 'javelin-stratcom', 920 + 'phabricator-prefab', 921 + 'phuix-icon-view', 922 + ), 912 923 '087e919c' => array( 913 924 'javelin-install', 914 925 'javelin-dom', ··· 921 932 'javelin-workflow', 922 933 'javelin-dom', 923 934 'javelin-router', 924 - ), 925 - '0b7a4f6e' => array( 926 - 'javelin-behavior', 927 - 'javelin-typeahead-ondemand-source', 928 - 'javelin-typeahead', 929 - 'javelin-dom', 930 - 'javelin-uri', 931 - 'javelin-util', 932 - 'javelin-stratcom', 933 - 'phabricator-prefab', 934 935 ), 935 936 '0f764c35' => array( 936 937 'javelin-install',
+4 -1
src/applications/diffusion/typeahead/DiffusionSymbolDatasource.php
··· 47 47 ->setPHID(md5($symbol->getURI())) // Just needs to be unique. 48 48 ->setDisplayName($name) 49 49 ->setDisplayType(strtoupper($lang).' '.ucwords($type).' ('.$repo.')') 50 - ->setPriorityType('symb'); 50 + ->setPriorityType('symb') 51 + ->setImageSprite( 52 + 'phabricator-search-icon phui-font-fa phui-icon-view fa-code '. 53 + 'lightgreytext'); 51 54 } 52 55 } 53 56
+1 -1
src/applications/project/storage/PhabricatorProject.php
··· 379 379 $this->getPHID()); 380 380 381 381 $all_strings = ipull($slugs, 'slug'); 382 - $all_strings[] = $this->getName(); 382 + $all_strings[] = $this->getDisplayName(); 383 383 $all_strings = implode(' ', $all_strings); 384 384 385 385 $tokens = PhabricatorTypeaheadDatasource::tokenizeString($all_strings);
+1 -1
src/applications/project/typeahead/PhabricatorProjectDatasource.php
··· 70 70 $proj_result = id(new PhabricatorTypeaheadResult()) 71 71 ->setName($all_strings) 72 72 ->setDisplayName($proj->getDisplayName()) 73 - ->setDisplayType(pht('Project')) 73 + ->setDisplayType($proj->getDisplayIconName()) 74 74 ->setURI($proj->getURI()) 75 75 ->setPHID($proj->getPHID()) 76 76 ->setIcon($proj->getDisplayIconIcon())
+11
webroot/rsrc/js/core/behavior-search-typeahead.js
··· 8 8 * javelin-util 9 9 * javelin-stratcom 10 10 * phabricator-prefab 11 + * phuix-icon-view 11 12 */ 12 13 13 14 JX.behavior('phabricator-search-typeahead', function(config) { ··· 25 26 attr.style = {backgroundImage: 'url('+object.imageURI+')'}; 26 27 } 27 28 29 + var icon = null; 30 + if (object.icon) { 31 + icon = new JX.PHUIXIconView() 32 + .setIcon(object.icon) 33 + .setColor('lightgreytext') 34 + .getNode(); 35 + icon = [icon, ' ']; 36 + } 37 + 28 38 var render = JX.$N( 29 39 'span', 30 40 attr, 31 41 [ 32 42 JX.$N('span', {className: object.sprite}), 33 43 JX.$N('span', {className: 'result-name'}, object.displayName), 44 + icon, 34 45 JX.$N('span', {className: 'result-type'}, object.type) 35 46 ]); 36 47