Fixes T11971, adds a basic typeahead for selecting an icon.
Details
Diff Detail
- Repository
- rP Phabricator
- Branch
- icon_typeahead (branched from master)
- Lint
Lint Passed - Unit
Tests Passed - Build Status
Buildable 15508 Build 20446: Run Core Tests Build 20445: arc lint + arc unit
Event Timeline
This UX seems a bit questionable to me, to the point where replacing a 16-up icon picker with this might actually be a worse experience because it's so hard to find anything relevant, even though you have more stuff to choose from?
Since I know they exist I could open the list on FontAwesome or UIExamples in another tab, find what I'm looking for, then search for it in this UI -- but users may not know to do that.
Beyond having many icons which users are almost certainly very very rarely interested in selecting (many brand icons, including some like fa-vine, which Twitter has shut down), there are also a lot of duplicates, like fa-y-combinator and fa-y-combinator-square and fa-yc-square. Allowing users to select duplicates might lead to problems with "search by icon", like we currently have in Projects. If fa-y-combinator, fa-y-combinator-square and fa-yc-square are three different icons, they might be three different queries if no part of the selection or search logic knows how to deduplicate them.
src/applications/macro/typeahead/PhabricatorIconDatasource.php | ||
---|---|---|
14 | I believe the datasource won't work if the paired application is uninstalled, and installs may reasonably remove Macro. Maybe put this in Files instead (which can not be uninstalled). |
This UX seems a bit questionable to me, to the point where replacing a 16-up icon picker with this might actually be a worse experience because it's so hard to find anything relevant, even though you have more stuff to choose from?
I don't think I said that anywhere. This is simple enough to deploy as an option on the icon-picker if the user wants more, though I wasn't planning on using it anywhere other than Badges right now for testing. Pick from our wonderful collection or assign your own.
There are pros and cons to both search and browse interfaces. I'm not too concerned though with this typeahead interface, since it's reasonably defined. When I go to FontAwesome to find something, I start with a few Command-F guesses and they usually hit. I think people who say, I know what I want and it's not in your 16, will be better served here.
I don't know we need these for Projects, if that's your main concern.
Yeah, major concern is how this sets us up for projects. The existence of that task is why I thought this was headed toward projects soon-ish.
I also assumed the 16-up was getting replaced by this rather than supplemented.
I imagine the UI we'd truly prefer for this is something closer to the Slack emoji picker screenshot in T12139 (i.e., group and categorize icons, sort similar icons together, show lots of icons on one screen, sort default/popular/recent icons to the top)? But maybe "16-up + escape hatch to get a typeahead" or whatever is a reasonable step toward that without needing to actually build it.
I dug around font awesome source and they don't currently more metadata but I can file a request for it in version 5
I don't mind just writing the metadata by hand, although I'd vaguely like to come up with an approach on "translatable lists which may have different lengths in different languages" first. I'm leaning toward just using newlines as a delimiter or something, though.
FA 5 will have category packs and they just invited us to secret repo / tracker for our donation.
I think it's perfectly fine if you know you're looking for an icon for a book.
If you want an icon for a scotch tasting, maybe you search "scotch", "drink", "whiskey", "whisky", "cup", "mug", "flagon", "stein", "party", "fun" -- none of which give you any hits -- and then give up and pick because whatever, and go tweet about how Phabricator sucks.
But maybe that won't be an issue in practice.